users@jaxb.java.net

Customizing with binding.xjc

From: Lulseged Zerfu <zlulseged_at_hotmail.com>
Date: Sat, 17 Nov 2012 22:23:22 +0000

Hi
 I am trying to create binding.xjb to go arround schema problem but was not successful.
Can any one help?
There are two publicId defined and one of the publicId need to be customized with binding.xjc which I tried but my XPATH looks not working.

....<xs:element name="createMMTelSchedConf" substitutionGroup="cai3g:CreateMODefinition"> <xs:annotation> <xs:documentation xml:lang="en">Used to create an MMTel scheduled conference sevice.</xs:documentation> </xs:annotation> <xs:complexType> <xs:complexContent> <xs:extension base="cai3g:AbstractCreateAttributeType"> <xs:sequence> <xs:element name="publicId" type="publicIdentityType"> <xs:annotation> <xs:documentation xml:lang="en"> The identity of the user. This identity must already be configured on the HSS. </xs:documentation> </xs:annotation> </xs:element> <!-- the relative order of the existing services must be maintained --> <!-- all new services shall be optional and inserted in alphabetical order within the existing list where possible --> <xs:element ref="scheduled-conference" /> </xs:sequence> <xs:attribute name="publicId" type="publicIdentityType" use="required" /> </xs:extension> </xs:complexContent> </xs:complexType>....

My binding file looks like:
....<jxb:bindings schemaLocation="mmtel-aggregated-schedconf.xsd" node="/xs:schema"> <jxb:schemaBindings> <jxb:package name="com.ericsson.ims.mtas.xdms.schema.aggregated.scheduled.conference" /> </jxb:schemaBindings>
                <bindings node="/xs:schema/xs:element[@name='createMMTelSchedConf']/xs:complexType/xs:complexContent"> <bindings node="/xs:extension[@name='AbstractCreateAttributeType']"> <bindings node="/xs:attribute[@name='publicId']"> <jxb:property name="PublicIdentityAttribute" /> </bindings> </bindings> </bindings>
        </jxb:bindings>....
Thanks in advance.
BRLulseged