[ 
https://issues.apache.org/jira/browse/AXIS2-5172?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Andrew Nastyn updated AXIS2-5172:
---------------------------------

    Attachment: xjc_omit_empty_property_values.patch

Patch to fix this bug
                
> JAXB-RI databinding issue. Axis2-wsdl2code-maven-plugin does not allow XJC 
> compiler properties w/o providing some value
> -----------------------------------------------------------------------------------------------------------------------
>
>                 Key: AXIS2-5172
>                 URL: https://issues.apache.org/jira/browse/AXIS2-5172
>             Project: Axis2
>          Issue Type: Bug
>          Components: databinding, modules
>    Affects Versions: 1.6.0, 1.6.1
>         Environment: Windows 7 x64, Sun JDK 1.6
>            Reporter: Andrew Nastyn
>              Labels: patch
>         Attachments: xjc_omit_empty_property_values.patch
>
>
> Example plugin configuration (jaxbri databinding):
> <plugin>
>                 <groupId>org.apache.axis2</groupId>
>                 <artifactId>axis2-wsdl2code-maven-plugin</artifactId>
>                 <version>1.6.1</version>
>                 <executions>
>                     <execution>
>                         <id>generate service skeleton</id>
>                         <phase>generate-sources</phase>
>                         <inherited>false</inherited>
>                         <goals>
>                             <goal>wsdl2code</goal>
>                         </goals>
>                         <configuration>
>                             <packageName>...</packageName>
>                             <generateAllClasses>false</generateAllClasses>
>                             <generateServerSide>true</generateServerSide>
>                             <databindingName>jaxbri</databindingName>
>                             
> <generateServerSideInterface>true</generateServerSideInterface>
>                             <skipMessageReceiver>true</skipMessageReceiver>
>                             <generateServicesXml>true</generateServicesXml>
>                             <wsdlFile>SomeService.wsdl</wsdlFile>
>                             <namespaceURIs>
>                                 <namespaceURI>
>                                     <uri>...</uri>
>                                     <packageName>...</packageName>
>                                 </namespaceURI>
>                             </namespaceURIs>
>                             <options>
>                                 <property>
>                                     <name>bindingFileName</name>
>                                     <value>binding.jxb</value>
>                                 </property>
>                                 <!-- generate toString methods -->
>                                 <property>
>                                     <name>XtoString</name>
>                                     <value>someString</value>
>                                 </property>
>                                 <!-- generate equals methods -->
>                                 <property>
>                                     <name>Xequals</name>
>                                     <value>someString</value>
>                                 </property>
>                                 <!-- generate hashCode methods -->
>                                 <property>
>                                     <name>XhashCode</name>
>                                     <value>someString</value>
>                                 </property>
>                             </options>
>                         </configuration>
>                     </execution>
>                 </executions>
>                 <dependencies>
>                     <dependency>
>                         <groupId>org.apache.axis2</groupId>
>                         <artifactId>axis2-jaxbri</artifactId>
>                         <version>1.6.1</version>
>                     </dependency>
>                     <dependency>
>                          <groupId>org.apache.axis2</groupId>
>                          <artifactId>axis2-codegen</artifactId>
>                          <version>1.6.1</version>
>                     </dependency>
>                     <dependency>
>                         <groupId>org.jvnet.jaxb2_commons</groupId>
>                         <artifactId>jaxb2-basics</artifactId>
>                         <version>${jaxb2.basics.version}</version>
>                     </dependency>
>                     <dependency>
>                         <groupId>org.jvnet.jaxb2_commons</groupId>
>                         <artifactId>jaxb2-basics-annotate</artifactId>
>                         <version>${jaxb2.basics.annotate.version}</version>
>                     </dependency>
>                     <dependency>
>                         <groupId>com.sun.xml.bind</groupId>
>                         <artifactId>jaxb-impl</artifactId>
>                         <version>${jaxb.version}</version>
>                     </dependency>
>                     <dependency>
>                         <groupId>com.sun.xml.bind</groupId>
>                         <artifactId>jaxb-xjc</artifactId>
>                         <version>${jaxb.version}</version>
>                     </dependency>
>                 </dependencies>
> </plugin>
> The properties XtoString, Xequals, XhashCode don't have any values.
> Because of the bug you must provide some string values and can't completely 
> omit <value> element like this:
>                                 <!-- generate toString methods -->
>                                 <property>
>                                     <name>XtoString</name>
>                                 </property>
>                                 <!-- generate equals methods -->
>                                 <property>
>                                     <name>Xequals</name>
>                                 </property>
>                                 <!-- generate hashCode methods -->
>                                 <property>
>                                     <name>XhashCode</name>
>                                 </property>
> I'll attach patch for this.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to