Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <xsd:complexType name="Person">
- <xsd:annotation>
- <xsd:appinfo>
- <jxb:property name="car">
- <jxb:baseType name="com.example.Car"/>
- </jxb:property>
- </xsd:appinfo>
- </xsd:annotation>
- <xsd:attribute name="car" type="xsd:IDREF"/>
- </xsd:complexType>
- <xsd:complexType name="Car">
- <xsd:attribute name="id" type="xsd:ID"/>
- </xsd:complexType>
- @XmlAccessorType(XmlAccessType.FIELD)
- @XmlType(name = "Person")
- public class Person {
- @XmlAttribute(name = "car")
- @XmlIDREF
- @XmlSchemaType(name = "IDREF")
- protected Object car;
- public Object getCar() {
- return car;
- }
- public void setCar(Object value) {
- this.car = value;
- }
- }
- @XmlAccessorType(XmlAccessType.FIELD)
- @XmlType(name = "Car")
- public class Car {
- @XmlAttribute(name = "id")
- @XmlJavaTypeAdapter(CollapsedStringAdapter.class)
- @XmlID
- @XmlSchemaType(name = "ID")
- protected String id;
- public String getId() {
- return id;
- }
- public void setId(String value) {
- this.id = value;
- }
- }
- <xs:attribute name="idRef" type="xs:IDREF">
- <xs:annotation>
- <xs:appinfo>
- <jaxb:property>
- <jaxb:baseType name="PractitionerType"/>
- </jaxb:property>
- </xs:appinfo>
- </xs:annotation>
- </xs:attribute>
- @XmlAttribute(name = "idRef")
- @XmlIDREF
- @XmlSchemaType(name = "IDREF")
- protected PractitionerType idRef;
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement