Currently, the way I integrate maven2 and jibx into my project is to specify the repository inside my POM: <repositories> <!-- add in jibx repository --> <repository> <releases> <enabled>true</enabled> <updatePolicy>never</updatePolicy> </releases> <snapshots> <enabled>false</enabled> </snapshots> <id>jibx.sf.net</id> <name>JiBX Repository</name> <url>http://jibx.sf.net/maven2</url> </repository> </repositories> Then I add the dependency: <dependency> <groupId>org.jibx</groupId> <artifactId>jibx-extras</artifactId> <version>1.1</version> <scope>test</scope> </dependency> <dependency> <groupId>org.jibx</groupId> <artifactId>jibx-bind</artifactId> <version>1.1</version> <scope>compile</scope> </dependency> <dependency> <groupId>bcel</groupId> <artifactId>bcel</artifactId> <version>5.1</version> <scope>compile</scope> </dependency> <dependency> <groupId>xpp3</groupId> <artifactId>xpp3</artifactId> <version>1.1.3.4.O</version> </dependency> <dependency> <groupId>org.jibx</groupId> <artifactId>jibx-run</artifactId> <version>1.1</version> </dependency> Currently, I don't believe there's a jibx plugin to work with maven2 to do the binding, so I am using ANT script within maven2 to do the jibx binding right after compilation: <!-- run jibx binding after classes are compiled --> <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-antrun-plugin</artifactId> <executions> <execution> <phase>process-classes</phase> <configuration> <tasks> <taskdef name="bind" classname="org.jibx.binding.ant.CompileTask"> <classpath refid="maven.compile.classpath"/> </taskdef> <bind verbose="false" load="true"> <bindingfileset dir="${basedir}/bindings"/> <classpathset dir="${project.build.outputDirectory}"/> </bind> </tasks> </configuration> <goals> <goal>run</goal> </goals> <inherited>true</inherited> </execution> </executions> </plugin> This is working out perfectly because right after compilation, it will process the classes and do the bindings. After that, it will run the tests, which essentially works as expected. Hope this helps. Thanks, Chris On Jun 26, 2006, at 9:39 PM, Henri Dupre wrote:
|
Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
_______________________________________________ jibx-users mailing list jibx-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jibx-users