-
Notifications
You must be signed in to change notification settings - Fork 33
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Transferring also @XmlElementRef annotation (fixes #33).
- Loading branch information
Showing
13 changed files
with
742 additions
and
7 deletions.
There are no files selected for viewing
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,3 @@ | ||
#Fri Feb 24 15:46:49 CET 2012 | ||
eclipse.preferences.version=1 | ||
formatter_profile=_Eclipse (Common) | ||
formatter_profile=_Eclipse-based common (XEW) | ||
formatter_settings_version=12 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
64 changes: 64 additions & 0 deletions
64
src/test/generated_resources/substitution_groups/Address.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,64 @@ | ||
|
||
package substitution_groups; | ||
|
||
import javax.xml.bind.annotation.XmlAccessType; | ||
import javax.xml.bind.annotation.XmlAccessorType; | ||
import javax.xml.bind.annotation.XmlElement; | ||
import javax.xml.bind.annotation.XmlType; | ||
|
||
|
||
/** | ||
* <p>Java class for addressType complex type. | ||
* | ||
* <p>The following schema fragment specifies the expected content contained within this class. | ||
* | ||
* <pre> | ||
* <complexType name="addressType"> | ||
* <complexContent> | ||
* <extension base="{}contactInfoType"> | ||
* <sequence> | ||
* <element name="street" type="{http://www.w3.org/2001/XMLSchema}string"/> | ||
* </sequence> | ||
* </extension> | ||
* </complexContent> | ||
* </complexType> | ||
* </pre> | ||
* | ||
* | ||
*/ | ||
@XmlAccessorType(XmlAccessType.FIELD) | ||
@XmlType(name = "addressType", propOrder = { | ||
"street" | ||
}) | ||
public class Address | ||
extends ContactInfo | ||
{ | ||
|
||
@XmlElement(required = true) | ||
protected String street; | ||
|
||
/** | ||
* Gets the value of the street property. | ||
* | ||
* @return | ||
* possible object is | ||
* {@link String } | ||
* | ||
*/ | ||
public String getStreet() { | ||
return street; | ||
} | ||
|
||
/** | ||
* Sets the value of the street property. | ||
* | ||
* @param value | ||
* allowed object is | ||
* {@link String } | ||
* | ||
*/ | ||
public void setStreet(String value) { | ||
this.street = value; | ||
} | ||
|
||
} |
35 changes: 35 additions & 0 deletions
35
src/test/generated_resources/substitution_groups/ContactInfo.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
|
||
package substitution_groups; | ||
|
||
import javax.xml.bind.annotation.XmlAccessType; | ||
import javax.xml.bind.annotation.XmlAccessorType; | ||
import javax.xml.bind.annotation.XmlSeeAlso; | ||
import javax.xml.bind.annotation.XmlType; | ||
|
||
|
||
/** | ||
* <p>Java class for contactInfoType complex type. | ||
* | ||
* <p>The following schema fragment specifies the expected content contained within this class. | ||
* | ||
* <pre> | ||
* <complexType name="contactInfoType"> | ||
* <complexContent> | ||
* <restriction base="{http://www.w3.org/2001/XMLSchema}anyType"> | ||
* </restriction> | ||
* </complexContent> | ||
* </complexType> | ||
* </pre> | ||
* | ||
* | ||
*/ | ||
@XmlAccessorType(XmlAccessType.FIELD) | ||
@XmlType(name = "contactInfoType") | ||
@XmlSeeAlso({ | ||
Address.class, | ||
PhoneNumber.class | ||
}) | ||
public abstract class ContactInfo { | ||
|
||
|
||
} |
61 changes: 61 additions & 0 deletions
61
src/test/generated_resources/substitution_groups/Customer.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,61 @@ | ||
|
||
package substitution_groups; | ||
|
||
import java.util.ArrayList; | ||
import java.util.List; | ||
import javax.xml.bind.JAXBElement; | ||
import javax.xml.bind.annotation.XmlAccessType; | ||
import javax.xml.bind.annotation.XmlAccessorType; | ||
import javax.xml.bind.annotation.XmlElementRef; | ||
import javax.xml.bind.annotation.XmlElementWrapper; | ||
import javax.xml.bind.annotation.XmlType; | ||
|
||
|
||
/** | ||
* <p>Java class for customerType complex type. | ||
* | ||
* <p>The following schema fragment specifies the expected content contained within this class. | ||
* | ||
* <pre> | ||
* <complexType name="customerType"> | ||
* <complexContent> | ||
* <restriction base="{http://www.w3.org/2001/XMLSchema}anyType"> | ||
* <sequence> | ||
* <element name="contact-infos" minOccurs="0"> | ||
* <complexType> | ||
* <complexContent> | ||
* <restriction base="{http://www.w3.org/2001/XMLSchema}anyType"> | ||
* <sequence> | ||
* <element ref="{}contact-info" maxOccurs="unbounded" minOccurs="0"/> | ||
* </sequence> | ||
* </restriction> | ||
* </complexContent> | ||
* </complexType> | ||
* </element> | ||
* </sequence> | ||
* </restriction> | ||
* </complexContent> | ||
* </complexType> | ||
* </pre> | ||
* | ||
* | ||
*/ | ||
@XmlAccessorType(XmlAccessType.FIELD) | ||
@XmlType(name = "customerType", propOrder = { | ||
"contactInfos" | ||
}) | ||
public class Customer { | ||
|
||
@XmlElementWrapper(name = "contact-infos") | ||
@XmlElementRef(name = "contact-info", type = JAXBElement.class, required = false) | ||
protected List<JAXBElement<? extends ContactInfo>> contactInfos = new ArrayList<JAXBElement<? extends ContactInfo>>(); | ||
|
||
public List<JAXBElement<? extends ContactInfo>> getContactInfos() { | ||
return contactInfos; | ||
} | ||
|
||
public void setContactInfos(List<JAXBElement<? extends ContactInfo>> contactInfos) { | ||
this.contactInfos = contactInfos; | ||
} | ||
|
||
} |
99 changes: 99 additions & 0 deletions
99
src/test/generated_resources/substitution_groups/ObjectFactory.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,99 @@ | ||
|
||
package substitution_groups; | ||
|
||
import javax.xml.bind.JAXBElement; | ||
import javax.xml.bind.annotation.XmlElementDecl; | ||
import javax.xml.bind.annotation.XmlRegistry; | ||
import javax.xml.namespace.QName; | ||
|
||
|
||
/** | ||
* This object contains factory methods for each | ||
* Java content interface and Java element interface | ||
* generated in the substitution_groups package. | ||
* <p>An ObjectFactory allows you to programatically | ||
* construct new instances of the Java representation | ||
* for XML content. The Java representation of XML | ||
* content can consist of schema derived interfaces | ||
* and classes representing the binding of schema | ||
* type definitions, element declarations and model | ||
* groups. Factory methods for each of these are | ||
* provided in this class. | ||
* | ||
*/ | ||
@XmlRegistry | ||
public class ObjectFactory { | ||
|
||
private final static QName _ContactInfo_QNAME = new QName("", "contact-info"); | ||
private final static QName _Address_QNAME = new QName("", "address"); | ||
private final static QName _Customer_QNAME = new QName("", "customer"); | ||
private final static QName _PhoneNumber_QNAME = new QName("", "phone-number"); | ||
|
||
/** | ||
* Create a new ObjectFactory that can be used to create new instances of schema derived classes for package: substitution_groups | ||
* | ||
*/ | ||
public ObjectFactory() { | ||
} | ||
|
||
/** | ||
* Create an instance of {@link Customer } | ||
* | ||
*/ | ||
public Customer createCustomer() { | ||
return new Customer(); | ||
} | ||
|
||
/** | ||
* Create an instance of {@link Address } | ||
* | ||
*/ | ||
public Address createAddress() { | ||
return new Address(); | ||
} | ||
|
||
/** | ||
* Create an instance of {@link PhoneNumber } | ||
* | ||
*/ | ||
public PhoneNumber createPhoneNumber() { | ||
return new PhoneNumber(); | ||
} | ||
|
||
/** | ||
* Create an instance of {@link JAXBElement }{@code <}{@link ContactInfo }{@code >}} | ||
* | ||
*/ | ||
@XmlElementDecl(namespace = "", name = "contact-info") | ||
public JAXBElement<ContactInfo> createContactInfo(ContactInfo value) { | ||
return new JAXBElement<ContactInfo>(_ContactInfo_QNAME, ContactInfo.class, null, value); | ||
} | ||
|
||
/** | ||
* Create an instance of {@link JAXBElement }{@code <}{@link Address }{@code >}} | ||
* | ||
*/ | ||
@XmlElementDecl(namespace = "", name = "address", substitutionHeadNamespace = "", substitutionHeadName = "contact-info") | ||
public JAXBElement<Address> createAddress(Address value) { | ||
return new JAXBElement<Address>(_Address_QNAME, Address.class, null, value); | ||
} | ||
|
||
/** | ||
* Create an instance of {@link JAXBElement }{@code <}{@link Customer }{@code >}} | ||
* | ||
*/ | ||
@XmlElementDecl(namespace = "", name = "customer") | ||
public JAXBElement<Customer> createCustomer(Customer value) { | ||
return new JAXBElement<Customer>(_Customer_QNAME, Customer.class, null, value); | ||
} | ||
|
||
/** | ||
* Create an instance of {@link JAXBElement }{@code <}{@link PhoneNumber }{@code >}} | ||
* | ||
*/ | ||
@XmlElementDecl(namespace = "", name = "phone-number", substitutionHeadNamespace = "", substitutionHeadName = "contact-info") | ||
public JAXBElement<PhoneNumber> createPhoneNumber(PhoneNumber value) { | ||
return new JAXBElement<PhoneNumber>(_PhoneNumber_QNAME, PhoneNumber.class, null, value); | ||
} | ||
|
||
} |
92 changes: 92 additions & 0 deletions
92
src/test/generated_resources/substitution_groups/PhoneNumber.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,92 @@ | ||
|
||
package substitution_groups; | ||
|
||
import javax.xml.bind.annotation.XmlAccessType; | ||
import javax.xml.bind.annotation.XmlAccessorType; | ||
import javax.xml.bind.annotation.XmlElement; | ||
import javax.xml.bind.annotation.XmlType; | ||
|
||
|
||
/** | ||
* <p>Java class for phoneNumberType complex type. | ||
* | ||
* <p>The following schema fragment specifies the expected content contained within this class. | ||
* | ||
* <pre> | ||
* <complexType name="phoneNumberType"> | ||
* <complexContent> | ||
* <extension base="{}contactInfoType"> | ||
* <sequence> | ||
* <element name="area-number" type="{http://www.w3.org/2001/XMLSchema}string"/> | ||
* <element name="phone-number" type="{http://www.w3.org/2001/XMLSchema}string"/> | ||
* </sequence> | ||
* </extension> | ||
* </complexContent> | ||
* </complexType> | ||
* </pre> | ||
* | ||
* | ||
*/ | ||
@XmlAccessorType(XmlAccessType.FIELD) | ||
@XmlType(name = "phoneNumberType", propOrder = { | ||
"areaNumber", | ||
"phoneNumber" | ||
}) | ||
public class PhoneNumber | ||
extends ContactInfo | ||
{ | ||
|
||
@XmlElement(name = "area-number", required = true) | ||
protected String areaNumber; | ||
@XmlElement(name = "phone-number", required = true) | ||
protected String phoneNumber; | ||
|
||
/** | ||
* Gets the value of the areaNumber property. | ||
* | ||
* @return | ||
* possible object is | ||
* {@link String } | ||
* | ||
*/ | ||
public String getAreaNumber() { | ||
return areaNumber; | ||
} | ||
|
||
/** | ||
* Sets the value of the areaNumber property. | ||
* | ||
* @param value | ||
* allowed object is | ||
* {@link String } | ||
* | ||
*/ | ||
public void setAreaNumber(String value) { | ||
this.areaNumber = value; | ||
} | ||
|
||
/** | ||
* Gets the value of the phoneNumber property. | ||
* | ||
* @return | ||
* possible object is | ||
* {@link String } | ||
* | ||
*/ | ||
public String getPhoneNumber() { | ||
return phoneNumber; | ||
} | ||
|
||
/** | ||
* Sets the value of the phoneNumber property. | ||
* | ||
* @param value | ||
* allowed object is | ||
* {@link String } | ||
* | ||
*/ | ||
public void setPhoneNumber(String value) { | ||
this.phoneNumber = value; | ||
} | ||
|
||
} |
1 change: 1 addition & 0 deletions
1
src/test/generated_resources/substitution_groups/package-info.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
package substitution_groups; |
Oops, something went wrong.