[ 
https://jira.codehaus.org/browse/JIBX-450?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=276749#comment-276749
 ] 

Klaus Claszen commented on JIBX-450:
------------------------------------

Oh, I did not noticed that there are 2 plugin versions. <schemaLocation> indeed 
works perfect with the jibx-maven-plugin:1.2.3. 

Thanks for directing me to the new standard!
Klaus


> Property name <schemaLocation> has to be <schemaDirectory> for schema-codegen 
> goal.
> -----------------------------------------------------------------------------------
>
>                 Key: JIBX-450
>                 URL: https://jira.codehaus.org/browse/JIBX-450
>             Project: JiBX
>          Issue Type: Bug
>          Components: maven plugin
>    Affects Versions: JiBX 1.2.3
>            Reporter: Klaus Claszen
>            Assignee: Don Corley
>            Priority: Minor
>             Fix For: JiBX 1.2.3
>
>
> I tried to run the schema-codegen goal with the 
> [documented|http://jibx.sourceforge.net/maven-jibx-plugin/schema-codegen-mojo.html#schemaLocation]
>  configuration property *<schemaLocation>* (which replaces the deprecated 
> *<directory>* property) like this:
> {noformat}
> <plugin>
>       <groupId>org.jibx</groupId>
>       <artifactId>maven-jibx-plugin</artifactId>
>       <version>1.2.3</version>
>       <executions>
>               <execution>
>                       <id>generate-java-code-from-schema</id>
>                       <phase>generate-sources</phase>
>                       <goals>
>                               <goal>schema-codegen</goal>
>                       </goals>
>                       <configuration>
>                               
> <schemaLocation>src/main/resources</schemaLocation>
>                               <includeSchemas>
>                                       
> <includeSchema>foobar.xsd</includeSchema>
>                               </includeSchemas>
>                               <verbose>true</verbose>
>                               
> <targetDirectory>target/generated-jibx-sources</targetDirectory>
>                       </configuration>
>               </execution>
>               <execution>
>                       <id>compile-binding</id>
>                       <phase>process-classes</phase>
>                       <goals>
>                               <goal>bind</goal>
>                       </goals>
>                       <configuration>
>                               
> <schemaBindingDirectory>target/generated-jibx-sources</schemaBindingDirectory>
>                               <includeSchemaBindings>
>                                       
> <includeSchemaBinding>binding.xml</includeSchemaBinding>
>                               </includeSchemaBindings>
>                               <load>true</load>
>                               <validate>true</validate>
>                               <verify>true</verify>
>                       </configuration>
>               </execution>
>       </executions>
> </plugin>
> {noformat}
> This did not work. A look at the maven debug configuration output shows, that 
> the expected property name is *<schemaDirectory>*.
> {noformat}
> [DEBUG] 
> -----------------------------------------------------------------------
> [DEBUG] Goal:          org.jibx:maven-jibx-plugin:1.2.3:schema-codegen 
> (generate-java-code-from-schema)
> [DEBUG] Style:         Regular
> [DEBUG] Configuration: <?xml version="1.0" encoding="UTF-8"?>
> <configuration>
>   <customizations>${customizations}</customizations>
>   <directory default-value="src/main/config">${directory}</directory>
>   <excludeSchemaBindings>${excludeSchemaBindings}</excludeSchemaBindings>
>   <excludeSchemas>${excludeSchemas}</excludeSchemas>
>   <excludes>${excludes}</excludes>
>   <includeBaseBindings>${includeBaseBindings}</includeBaseBindings>
>   <includeBindings>${includeBindings}</includeBindings>
>   <includeSchemaBindings>${includeSchemaBindings}</includeSchemaBindings>
>   <includeSchemas>
>     
> <includeSchema>foobar.xsd</includeSchema>${includeSchemas}</includeSchemas>
>   <includes>${includes}</includes>
>   <modules>${modules}</modules>
>   <multimodule default-value="false">${multi-module}</multimodule>
>   <project>${project}</project>
>   <schemaDirectory 
> default-value="src/main/config">${schemaDirectory}</schemaDirectory>
>   <targetDirectory 
> default-value="target/generated-sources">target/generated-jibx-sources</targetDirectory>
>   <verbose default-value="false">true</verbose>
> </configuration>
> [DEBUG] 
> -----------------------------------------------------------------------
> {noformat}

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

------------------------------------------------------------------------------
Get a FREE DOWNLOAD! and learn more about uberSVN rich system, 
user administration capabilities and model configuration. Take 
the hassle out of deploying and managing Subversion and the 
tools developers use with it. http://p.sf.net/sfu/wandisco-d2d-2
_______________________________________________
jibx-devs mailing list
jibx-devs@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jibx-devs

Reply via email to