Error in eclipse Ant Build using ibator [message #75784] |
Mon, 19 January 2009 03:13 |
Eclipse User |
|
|
|
Originally posted by: fafy_99.yahoo.com
Hi,
I'm a brand new member here, and a brand new eclipse/ant/ibator user. I
tried my first Ant build in eclipse and spent all night to no avail, so I'm
hoping I could get some help here.
I created a Build.xml and a ibatorConfig.xml, and they are located in my
project directory "C:\projects\AFI\InputService". When I tried to build it
in eclipse, I keep getting the NullPointeException.
This is my simple Build.xml file:
<project default="genfiles" basedir="c:\projects\AFI\InputService\">
<property name="generated.source.dir" value="${basedir}" />
<target name="genfiles" description="Generate the files">
<taskdef name="ibator"
classname="org.apache.ibatis.ibator.ant.IbatorAntTask"
classpath="c:\Program
Files\eclipse\plugins\org.apache.ibatis.ibator.core_1.2.1\ib ator.jar " />
<ibator overwrite="true"
configfile="c:\projects\AFI\InputService\ibatorConfig.xml" verbose="true" >
<propertyset>
<propertyref name="generated.source.dir"/>
</propertyset>
</ibator>
</target>
</project>
This is my ibatorConfig.xml:
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE ibatorConfiguration
PUBLIC "-//Apache Software Foundation//DTD Apache iBATIS Ibator
Configuration 1.0//EN"
"http://ibatis.apache.org/dtd/ibator-config_1_0.dtd">
<ibatorConfiguration>
<classPathEntry location="c:\Program
Files\java\mysql-connector-java-5.1.7\mysql-connector-java-5 .1.7-bin.jar " />
<ibatorContext id="MySQLTables" targetRuntime="Ibatis2Java2">
<jdbcConnection driverClass="com.mysql.jdbc.Driver"
connectionURL="jdbc:mysql://localhost:3306/afi"
userId="root"
password="123456">
</jdbcConnection>
<javaModelGenerator targetPackage="InputService"
targetProject="InputService\src">
<property name="enableSubPackages" value="false" />
<property name="trimStrings" value="true" />
</javaModelGenerator>
<sqlMapGenerator targetPackage="InputService"
targetProject="InputService\src">
<property name="enableSubPackages" value="false" />
</sqlMapGenerator>
<table tableName="client_table_properties"
domainObjectName="ClientTableProperties" >
<property name="useActualColumnNames" value="false"/>
<columnOverride column="account_number" javaType="java.lang.Object"
jdbcType="LONG" />
</table>
</ibatorContext>
</ibatorConfiguration>
This is the error I got:
Buildfile: C:\projects\AFI\InputService\build.xml
genfiles:
[ibator] java.lang.NullPointerException
[ibator] at
org.apache.ibatis.ibator.api.IntrospectedTable.calculateDAOI mplementationPackage(IntrospectedTable.java:508)
[ibator] at
org.apache.ibatis.ibator.api.IntrospectedTable.initialize(In trospectedTable.java:479)
[ibator] at
org.apache.ibatis.ibator.config.IbatorContext.generateFiles( IbatorContext.java:493)
[ibator] at
org.apache.ibatis.ibator.api.Ibator.generate(Ibator.java:219 )
[ibator] at
org.apache.ibatis.ibator.ant.IbatorAntTask.execute(IbatorAnt Task.java:145)
[ibator] at
org.apache.tools.ant.UnknownElement.execute(UnknownElement.j ava:288)
[ibator] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
[ibator] at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
[ibator] at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown
Source)
[ibator] at java.lang.reflect.Method.invoke(Unknown Source)
[ibator] at
org.apache.tools.ant.dispatch.DispatchUtils.execute(Dispatch Utils.java:105)
[ibator] at org.apache.tools.ant.Task.perform(Task.java:348)
[ibator] at org.apache.tools.ant.Target.execute(Target.java:357)
[ibator] at org.apache.tools.ant.Target.performTasks(Target.java:385)
[ibator] at
org.apache.tools.ant.Project.executeSortedTargets(Project.ja va:1329)
[ibator] at
org.apache.tools.ant.Project.executeTarget(Project.java:1298 )
[ibator] at
org.apache.tools.ant.helper.DefaultExecutor.executeTargets(D efaultExecutor.java:41)
[ibator] at
org.eclipse.ant.internal.ui.antsupport.EclipseDefaultExecuto r.executeTargets(EclipseDefaultExecutor.java:32)
[ibator] at
org.apache.tools.ant.Project.executeTargets(Project.java:118 1)
[ibator] at
org.eclipse.ant.internal.ui.antsupport.InternalAntRunner.run (InternalAntRunner.java:423)
[ibator] at
org.eclipse.ant.internal.ui.antsupport.InternalAntRunner.mai n(InternalAntRunner.java:137)
BUILD FAILED
C:\projects\AFI\InputService\build.xml:8: null
Please point out what I'm missing here. Thank you very much for your help!
Shao Chin,
Tempe, AZ
|
|
|
Re: Error in eclipse Ant Build using ibator [message #75801 is a reply to message #75784] |
Mon, 19 January 2009 04:44 |
Wayne Beaton Messages: 554 Registered: December 2017 |
Senior Member |
|
|
I suspect that Eclipse is not the source of the problem. You can test
this for yourself by trying a simpler build.xml and confirming that
Eclipse can execute it as expected.
ibator is not part of any Eclipse project, so it's relatively unlikely
that you'll find any help for it here.
The org.apache.ibatis.ibator.api.IntrospectedTable type seems to be the
source of the error. This is part of the Apache ibatis project code. I
recommend that you seek answers on a forum from that project.
Good luck,
Wayne
shao wrote:
> Hi,
> I'm a brand new member here, and a brand new eclipse/ant/ibator user. I
> tried my first Ant build in eclipse and spent all night to no avail, so I'm
> hoping I could get some help here.
> I created a Build.xml and a ibatorConfig.xml, and they are located in my
> project directory "C:\projects\AFI\InputService". When I tried to build it
> in eclipse, I keep getting the NullPointeException.
>
> This is my simple Build.xml file:
>
> <project default="genfiles" basedir="c:\projects\AFI\InputService\">
> <property name="generated.source.dir" value="${basedir}" />
> <target name="genfiles" description="Generate the files">
> <taskdef name="ibator"
> classname="org.apache.ibatis.ibator.ant.IbatorAntTask"
> classpath="c:\Program
> Files\eclipse\plugins\org.apache.ibatis.ibator.core_1.2.1\ib ator.jar " />
> <ibator overwrite="true"
> configfile="c:\projects\AFI\InputService\ibatorConfig.xml" verbose="true" >
> <propertyset>
> <propertyref name="generated.source.dir"/>
> </propertyset>
> </ibator>
> </target>
> </project>
>
> This is my ibatorConfig.xml:
>
> <?xml version="1.0" encoding="UTF-8"?>
> <!DOCTYPE ibatorConfiguration
> PUBLIC "-//Apache Software Foundation//DTD Apache iBATIS Ibator
> Configuration 1.0//EN"
> "http://ibatis.apache.org/dtd/ibator-config_1_0.dtd">
>
> <ibatorConfiguration>
> <classPathEntry location="c:\Program
> Files\java\mysql-connector-java-5.1.7\mysql-connector-java-5 .1.7-bin.jar " />
>
> <ibatorContext id="MySQLTables" targetRuntime="Ibatis2Java2">
> <jdbcConnection driverClass="com.mysql.jdbc.Driver"
> connectionURL="jdbc:mysql://localhost:3306/afi"
> userId="root"
> password="123456">
> </jdbcConnection>
>
> <javaModelGenerator targetPackage="InputService"
> targetProject="InputService\src">
> <property name="enableSubPackages" value="false" />
> <property name="trimStrings" value="true" />
> </javaModelGenerator>
>
> <sqlMapGenerator targetPackage="InputService"
> targetProject="InputService\src">
> <property name="enableSubPackages" value="false" />
> </sqlMapGenerator>
>
> <table tableName="client_table_properties"
> domainObjectName="ClientTableProperties" >
> <property name="useActualColumnNames" value="false"/>
> <columnOverride column="account_number" javaType="java.lang.Object"
> jdbcType="LONG" />
> </table>
>
> </ibatorContext>
> </ibatorConfiguration>
>
> This is the error I got:
>
> Buildfile: C:\projects\AFI\InputService\build.xml
> genfiles:
> [ibator] java.lang.NullPointerException
> [ibator] at
> org.apache.ibatis.ibator.api.IntrospectedTable.calculateDAOI mplementationPackage(IntrospectedTable.java:508)
> [ibator] at
> org.apache.ibatis.ibator.api.IntrospectedTable.initialize(In trospectedTable.java:479)
> [ibator] at
> org.apache.ibatis.ibator.config.IbatorContext.generateFiles( IbatorContext.java:493)
> [ibator] at
> org.apache.ibatis.ibator.api.Ibator.generate(Ibator.java:219 )
> [ibator] at
> org.apache.ibatis.ibator.ant.IbatorAntTask.execute(IbatorAnt Task.java:145)
> [ibator] at
> org.apache.tools.ant.UnknownElement.execute(UnknownElement.j ava:288)
> [ibator] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> [ibator] at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
> [ibator] at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown
> Source)
> [ibator] at java.lang.reflect.Method.invoke(Unknown Source)
> [ibator] at
> org.apache.tools.ant.dispatch.DispatchUtils.execute(Dispatch Utils.java:105)
> [ibator] at org.apache.tools.ant.Task.perform(Task.java:348)
> [ibator] at org.apache.tools.ant.Target.execute(Target.java:357)
> [ibator] at org.apache.tools.ant.Target.performTasks(Target.java:385)
> [ibator] at
> org.apache.tools.ant.Project.executeSortedTargets(Project.ja va:1329)
> [ibator] at
> org.apache.tools.ant.Project.executeTarget(Project.java:1298 )
> [ibator] at
> org.apache.tools.ant.helper.DefaultExecutor.executeTargets(D efaultExecutor.java:41)
> [ibator] at
> org.eclipse.ant.internal.ui.antsupport.EclipseDefaultExecuto r.executeTargets(EclipseDefaultExecutor.java:32)
> [ibator] at
> org.apache.tools.ant.Project.executeTargets(Project.java:118 1)
> [ibator] at
> org.eclipse.ant.internal.ui.antsupport.InternalAntRunner.run (InternalAntRunner.java:423)
> [ibator] at
> org.eclipse.ant.internal.ui.antsupport.InternalAntRunner.mai n(InternalAntRunner.java:137)
>
> BUILD FAILED
> C:\projects\AFI\InputService\build.xml:8: null
>
> Please point out what I'm missing here. Thank you very much for your help!
> Shao Chin,
> Tempe, AZ
>
>
>
>
|
|
|
Re: Error in eclipse Ant Build using ibator [message #75818 is a reply to message #75801] |
Mon, 19 January 2009 05:17 |
Eclipse User |
|
|
|
Originally posted by: fafy_99.yahoo.com
Thanks Wayne.
You are right that the source of error is outside Eclipse. I tried the same
thing in command line, and I still got the same error. I'll try to get some
help from the ibatis project.
THanks,
SHao
"Wayne Beaton" <wayne@eclipse.org> wrote in message
news:gl10er$o4t$1@build.eclipse.org...
>I suspect that Eclipse is not the source of the problem. You can test this
>for yourself by trying a simpler build.xml and confirming that Eclipse can
>execute it as expected.
>
> ibator is not part of any Eclipse project, so it's relatively unlikely
> that you'll find any help for it here.
>
> The org.apache.ibatis.ibator.api.IntrospectedTable type seems to be the
> source of the error. This is part of the Apache ibatis project code. I
> recommend that you seek answers on a forum from that project.
>
> Good luck,
>
> Wayne
>
>
> shao wrote:
>> Hi,
>> I'm a brand new member here, and a brand new eclipse/ant/ibator user. I
>> tried my first Ant build in eclipse and spent all night to no avail, so
>> I'm
>> hoping I could get some help here.
>> I created a Build.xml and a ibatorConfig.xml, and they are located in my
>> project directory "C:\projects\AFI\InputService". When I tried to build
>> it
>> in eclipse, I keep getting the NullPointeException.
>>
>> This is my simple Build.xml file:
>>
>> <project default="genfiles" basedir="c:\projects\AFI\InputService\">
>> <property name="generated.source.dir" value="${basedir}" />
>> <target name="genfiles" description="Generate the files">
>> <taskdef name="ibator"
>>
>> classname="org.apache.ibatis.ibator.ant.IbatorAntTask"
>> classpath="c:\Program
>> Files\eclipse\plugins\org.apache.ibatis.ibator.core_1.2.1\ib ator.jar " />
>> <ibator overwrite="true"
>> configfile="c:\projects\AFI\InputService\ibatorConfig.xml" verbose="true"
>> >
>> <propertyset>
>> <propertyref name="generated.source.dir"/>
>> </propertyset>
>> </ibator>
>> </target>
>> </project>
>>
>> This is my ibatorConfig.xml:
>>
>> <?xml version="1.0" encoding="UTF-8"?>
>> <!DOCTYPE ibatorConfiguration
>> PUBLIC "-//Apache Software Foundation//DTD Apache iBATIS Ibator
>> Configuration 1.0//EN"
>> "http://ibatis.apache.org/dtd/ibator-config_1_0.dtd">
>>
>> <ibatorConfiguration>
>> <classPathEntry location="c:\Program
>> Files\java\mysql-connector-java-5.1.7\mysql-connector-java-5 .1.7-bin.jar "
>> />
>>
>> <ibatorContext id="MySQLTables" targetRuntime="Ibatis2Java2">
>> <jdbcConnection driverClass="com.mysql.jdbc.Driver"
>> connectionURL="jdbc:mysql://localhost:3306/afi"
>> userId="root"
>> password="123456">
>> </jdbcConnection>
>>
>> <javaModelGenerator targetPackage="InputService"
>> targetProject="InputService\src">
>> <property name="enableSubPackages" value="false" />
>> <property name="trimStrings" value="true" />
>> </javaModelGenerator>
>>
>> <sqlMapGenerator targetPackage="InputService"
>> targetProject="InputService\src">
>> <property name="enableSubPackages" value="false" />
>> </sqlMapGenerator>
>>
>> <table tableName="client_table_properties"
>> domainObjectName="ClientTableProperties" >
>> <property name="useActualColumnNames" value="false"/>
>> <columnOverride column="account_number" javaType="java.lang.Object"
>> jdbcType="LONG" />
>> </table>
>>
>> </ibatorContext>
>> </ibatorConfiguration>
>>
>> This is the error I got:
>>
>> Buildfile: C:\projects\AFI\InputService\build.xml
>> genfiles:
>> [ibator] java.lang.NullPointerException
>> [ibator] at
>> org.apache.ibatis.ibator.api.IntrospectedTable.calculateDAOI mplementationPackage(IntrospectedTable.java:508)
>> [ibator] at
>> org.apache.ibatis.ibator.api.IntrospectedTable.initialize(In trospectedTable.java:479)
>> [ibator] at
>> org.apache.ibatis.ibator.config.IbatorContext.generateFiles( IbatorContext.java:493)
>> [ibator] at
>> org.apache.ibatis.ibator.api.Ibator.generate(Ibator.java:219 )
>> [ibator] at
>> org.apache.ibatis.ibator.ant.IbatorAntTask.execute(IbatorAnt Task.java:145)
>> [ibator] at
>> org.apache.tools.ant.UnknownElement.execute(UnknownElement.j ava:288)
>> [ibator] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native
>> Method)
>> [ibator] at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown
>> Source)
>> [ibator] at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown
>> Source)
>> [ibator] at java.lang.reflect.Method.invoke(Unknown Source)
>> [ibator] at
>> org.apache.tools.ant.dispatch.DispatchUtils.execute(Dispatch Utils.java:105)
>> [ibator] at org.apache.tools.ant.Task.perform(Task.java:348)
>> [ibator] at org.apache.tools.ant.Target.execute(Target.java:357)
>> [ibator] at org.apache.tools.ant.Target.performTasks(Target.java:385)
>> [ibator] at
>> org.apache.tools.ant.Project.executeSortedTargets(Project.ja va:1329)
>> [ibator] at
>> org.apache.tools.ant.Project.executeTarget(Project.java:1298 )
>> [ibator] at
>> org.apache.tools.ant.helper.DefaultExecutor.executeTargets(D efaultExecutor.java:41)
>> [ibator] at
>> org.eclipse.ant.internal.ui.antsupport.EclipseDefaultExecuto r.executeTargets(EclipseDefaultExecutor.java:32)
>> [ibator] at
>> org.apache.tools.ant.Project.executeTargets(Project.java:118 1)
>> [ibator] at
>> org.eclipse.ant.internal.ui.antsupport.InternalAntRunner.run (InternalAntRunner.java:423)
>> [ibator] at
>> org.eclipse.ant.internal.ui.antsupport.InternalAntRunner.mai n(InternalAntRunner.java:137)
>>
>> BUILD FAILED
>> C:\projects\AFI\InputService\build.xml:8: null
>>
>> Please point out what I'm missing here. Thank you very much for your
>> help!
>> Shao Chin,
>> Tempe, AZ
>>
>>
>>
|
|
|
Re: Error in eclipse Ant Build using ibator [message #601909 is a reply to message #75784] |
Mon, 19 January 2009 04:44 |
Wayne Beaton Messages: 554 Registered: December 2017 |
Senior Member |
|
|
I suspect that Eclipse is not the source of the problem. You can test
this for yourself by trying a simpler build.xml and confirming that
Eclipse can execute it as expected.
ibator is not part of any Eclipse project, so it's relatively unlikely
that you'll find any help for it here.
The org.apache.ibatis.ibator.api.IntrospectedTable type seems to be the
source of the error. This is part of the Apache ibatis project code. I
recommend that you seek answers on a forum from that project.
Good luck,
Wayne
shao wrote:
> Hi,
> I'm a brand new member here, and a brand new eclipse/ant/ibator user. I
> tried my first Ant build in eclipse and spent all night to no avail, so I'm
> hoping I could get some help here.
> I created a Build.xml and a ibatorConfig.xml, and they are located in my
> project directory "C:\projects\AFI\InputService". When I tried to build it
> in eclipse, I keep getting the NullPointeException.
>
> This is my simple Build.xml file:
>
> <project default="genfiles" basedir="c:\projects\AFI\InputService\">
> <property name="generated.source.dir" value="${basedir}" />
> <target name="genfiles" description="Generate the files">
> <taskdef name="ibator"
> classname="org.apache.ibatis.ibator.ant.IbatorAntTask"
> classpath="c:\Program
> Files\eclipse\plugins\org.apache.ibatis.ibator.core_1.2.1\ib ator.jar " />
> <ibator overwrite="true"
> configfile="c:\projects\AFI\InputService\ibatorConfig.xml" verbose="true" >
> <propertyset>
> <propertyref name="generated.source.dir"/>
> </propertyset>
> </ibator>
> </target>
> </project>
>
> This is my ibatorConfig.xml:
>
> <?xml version="1.0" encoding="UTF-8"?>
> <!DOCTYPE ibatorConfiguration
> PUBLIC "-//Apache Software Foundation//DTD Apache iBATIS Ibator
> Configuration 1.0//EN"
> "http://ibatis.apache.org/dtd/ibator-config_1_0.dtd">
>
> <ibatorConfiguration>
> <classPathEntry location="c:\Program
> Files\java\mysql-connector-java-5.1.7\mysql-connector-java-5 .1.7-bin.jar " />
>
> <ibatorContext id="MySQLTables" targetRuntime="Ibatis2Java2">
> <jdbcConnection driverClass="com.mysql.jdbc.Driver"
> connectionURL="jdbc:mysql://localhost:3306/afi"
> userId="root"
> password="123456">
> </jdbcConnection>
>
> <javaModelGenerator targetPackage="InputService"
> targetProject="InputService\src">
> <property name="enableSubPackages" value="false" />
> <property name="trimStrings" value="true" />
> </javaModelGenerator>
>
> <sqlMapGenerator targetPackage="InputService"
> targetProject="InputService\src">
> <property name="enableSubPackages" value="false" />
> </sqlMapGenerator>
>
> <table tableName="client_table_properties"
> domainObjectName="ClientTableProperties" >
> <property name="useActualColumnNames" value="false"/>
> <columnOverride column="account_number" javaType="java.lang.Object"
> jdbcType="LONG" />
> </table>
>
> </ibatorContext>
> </ibatorConfiguration>
>
> This is the error I got:
>
> Buildfile: C:\projects\AFI\InputService\build.xml
> genfiles:
> [ibator] java.lang.NullPointerException
> [ibator] at
> org.apache.ibatis.ibator.api.IntrospectedTable.calculateDAOI mplementationPackage(IntrospectedTable.java:508)
> [ibator] at
> org.apache.ibatis.ibator.api.IntrospectedTable.initialize(In trospectedTable.java:479)
> [ibator] at
> org.apache.ibatis.ibator.config.IbatorContext.generateFiles( IbatorContext.java:493)
> [ibator] at
> org.apache.ibatis.ibator.api.Ibator.generate(Ibator.java:219 )
> [ibator] at
> org.apache.ibatis.ibator.ant.IbatorAntTask.execute(IbatorAnt Task.java:145)
> [ibator] at
> org.apache.tools.ant.UnknownElement.execute(UnknownElement.j ava:288)
> [ibator] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> [ibator] at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
> [ibator] at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown
> Source)
> [ibator] at java.lang.reflect.Method.invoke(Unknown Source)
> [ibator] at
> org.apache.tools.ant.dispatch.DispatchUtils.execute(Dispatch Utils.java:105)
> [ibator] at org.apache.tools.ant.Task.perform(Task.java:348)
> [ibator] at org.apache.tools.ant.Target.execute(Target.java:357)
> [ibator] at org.apache.tools.ant.Target.performTasks(Target.java:385)
> [ibator] at
> org.apache.tools.ant.Project.executeSortedTargets(Project.ja va:1329)
> [ibator] at
> org.apache.tools.ant.Project.executeTarget(Project.java:1298 )
> [ibator] at
> org.apache.tools.ant.helper.DefaultExecutor.executeTargets(D efaultExecutor.java:41)
> [ibator] at
> org.eclipse.ant.internal.ui.antsupport.EclipseDefaultExecuto r.executeTargets(EclipseDefaultExecutor.java:32)
> [ibator] at
> org.apache.tools.ant.Project.executeTargets(Project.java:118 1)
> [ibator] at
> org.eclipse.ant.internal.ui.antsupport.InternalAntRunner.run (InternalAntRunner.java:423)
> [ibator] at
> org.eclipse.ant.internal.ui.antsupport.InternalAntRunner.mai n(InternalAntRunner.java:137)
>
> BUILD FAILED
> C:\projects\AFI\InputService\build.xml:8: null
>
> Please point out what I'm missing here. Thank you very much for your help!
> Shao Chin,
> Tempe, AZ
>
>
>
>
|
|
|
Re: Error in eclipse Ant Build using ibator [message #601920 is a reply to message #75801] |
Mon, 19 January 2009 05:17 |
Eclipse User |
|
|
|
Originally posted by: fafy_99.yahoo.com
Thanks Wayne.
You are right that the source of error is outside Eclipse. I tried the same
thing in command line, and I still got the same error. I'll try to get some
help from the ibatis project.
THanks,
SHao
"Wayne Beaton" <wayne@eclipse.org> wrote in message
news:gl10er$o4t$1@build.eclipse.org...
>I suspect that Eclipse is not the source of the problem. You can test this
>for yourself by trying a simpler build.xml and confirming that Eclipse can
>execute it as expected.
>
> ibator is not part of any Eclipse project, so it's relatively unlikely
> that you'll find any help for it here.
>
> The org.apache.ibatis.ibator.api.IntrospectedTable type seems to be the
> source of the error. This is part of the Apache ibatis project code. I
> recommend that you seek answers on a forum from that project.
>
> Good luck,
>
> Wayne
>
>
> shao wrote:
>> Hi,
>> I'm a brand new member here, and a brand new eclipse/ant/ibator user. I
>> tried my first Ant build in eclipse and spent all night to no avail, so
>> I'm
>> hoping I could get some help here.
>> I created a Build.xml and a ibatorConfig.xml, and they are located in my
>> project directory "C:\projects\AFI\InputService". When I tried to build
>> it
>> in eclipse, I keep getting the NullPointeException.
>>
>> This is my simple Build.xml file:
>>
>> <project default="genfiles" basedir="c:\projects\AFI\InputService\">
>> <property name="generated.source.dir" value="${basedir}" />
>> <target name="genfiles" description="Generate the files">
>> <taskdef name="ibator"
>>
>> classname="org.apache.ibatis.ibator.ant.IbatorAntTask"
>> classpath="c:\Program
>> Files\eclipse\plugins\org.apache.ibatis.ibator.core_1.2.1\ib ator.jar " />
>> <ibator overwrite="true"
>> configfile="c:\projects\AFI\InputService\ibatorConfig.xml" verbose="true"
>> >
>> <propertyset>
>> <propertyref name="generated.source.dir"/>
>> </propertyset>
>> </ibator>
>> </target>
>> </project>
>>
>> This is my ibatorConfig.xml:
>>
>> <?xml version="1.0" encoding="UTF-8"?>
>> <!DOCTYPE ibatorConfiguration
>> PUBLIC "-//Apache Software Foundation//DTD Apache iBATIS Ibator
>> Configuration 1.0//EN"
>> "http://ibatis.apache.org/dtd/ibator-config_1_0.dtd">
>>
>> <ibatorConfiguration>
>> <classPathEntry location="c:\Program
>> Files\java\mysql-connector-java-5.1.7\mysql-connector-java-5 .1.7-bin.jar "
>> />
>>
>> <ibatorContext id="MySQLTables" targetRuntime="Ibatis2Java2">
>> <jdbcConnection driverClass="com.mysql.jdbc.Driver"
>> connectionURL="jdbc:mysql://localhost:3306/afi"
>> userId="root"
>> password="123456">
>> </jdbcConnection>
>>
>> <javaModelGenerator targetPackage="InputService"
>> targetProject="InputService\src">
>> <property name="enableSubPackages" value="false" />
>> <property name="trimStrings" value="true" />
>> </javaModelGenerator>
>>
>> <sqlMapGenerator targetPackage="InputService"
>> targetProject="InputService\src">
>> <property name="enableSubPackages" value="false" />
>> </sqlMapGenerator>
>>
>> <table tableName="client_table_properties"
>> domainObjectName="ClientTableProperties" >
>> <property name="useActualColumnNames" value="false"/>
>> <columnOverride column="account_number" javaType="java.lang.Object"
>> jdbcType="LONG" />
>> </table>
>>
>> </ibatorContext>
>> </ibatorConfiguration>
>>
>> This is the error I got:
>>
>> Buildfile: C:\projects\AFI\InputService\build.xml
>> genfiles:
>> [ibator] java.lang.NullPointerException
>> [ibator] at
>> org.apache.ibatis.ibator.api.IntrospectedTable.calculateDAOI mplementationPackage(IntrospectedTable.java:508)
>> [ibator] at
>> org.apache.ibatis.ibator.api.IntrospectedTable.initialize(In trospectedTable.java:479)
>> [ibator] at
>> org.apache.ibatis.ibator.config.IbatorContext.generateFiles( IbatorContext.java:493)
>> [ibator] at
>> org.apache.ibatis.ibator.api.Ibator.generate(Ibator.java:219 )
>> [ibator] at
>> org.apache.ibatis.ibator.ant.IbatorAntTask.execute(IbatorAnt Task.java:145)
>> [ibator] at
>> org.apache.tools.ant.UnknownElement.execute(UnknownElement.j ava:288)
>> [ibator] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native
>> Method)
>> [ibator] at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown
>> Source)
>> [ibator] at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown
>> Source)
>> [ibator] at java.lang.reflect.Method.invoke(Unknown Source)
>> [ibator] at
>> org.apache.tools.ant.dispatch.DispatchUtils.execute(Dispatch Utils.java:105)
>> [ibator] at org.apache.tools.ant.Task.perform(Task.java:348)
>> [ibator] at org.apache.tools.ant.Target.execute(Target.java:357)
>> [ibator] at org.apache.tools.ant.Target.performTasks(Target.java:385)
>> [ibator] at
>> org.apache.tools.ant.Project.executeSortedTargets(Project.ja va:1329)
>> [ibator] at
>> org.apache.tools.ant.Project.executeTarget(Project.java:1298 )
>> [ibator] at
>> org.apache.tools.ant.helper.DefaultExecutor.executeTargets(D efaultExecutor.java:41)
>> [ibator] at
>> org.eclipse.ant.internal.ui.antsupport.EclipseDefaultExecuto r.executeTargets(EclipseDefaultExecutor.java:32)
>> [ibator] at
>> org.apache.tools.ant.Project.executeTargets(Project.java:118 1)
>> [ibator] at
>> org.eclipse.ant.internal.ui.antsupport.InternalAntRunner.run (InternalAntRunner.java:423)
>> [ibator] at
>> org.eclipse.ant.internal.ui.antsupport.InternalAntRunner.mai n(InternalAntRunner.java:137)
>>
>> BUILD FAILED
>> C:\projects\AFI\InputService\build.xml:8: null
>>
>> Please point out what I'm missing here. Thank you very much for your
>> help!
>> Shao Chin,
>> Tempe, AZ
>>
>>
>>
|
|
|
Powered by
FUDForum. Page generated in 0.03133 seconds