Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 336393

Summary: [Validation] @XmlValue validation
Product: [WebTools] Dali JPA Tools Reporter: Karen Butzke <karenfbutzke>
Component: JAXBAssignee: Paul Fullbright <paul.fullbright>
Status: CLOSED DUPLICATE QA Contact:
Severity: enhancement    
Priority: P3 CC: neil.hauge, paul.fullbright
Version: 3.0   
Target Milestone: 3.1   
Hardware: PC   
OS: Windows XP   
Whiteboard:
Bug Depends on: 336388    
Bug Blocks:    

Description Karen Butzke CLA 2011-02-04 14:51:08 EST
1.If the type of the field or property is a collection type, then the collection item type must map to a simple schema type. Examples:
// Examples (not exhaustive): Legal usage of @XmlValue
	@XmlValue List<Integer> foo; // int maps to xs:int
	@XmlValue String[] foo; // String maps to xs:string
	@XmlValue List<Bar> foo; // only if Bar maps to a simple schema type

2.If the type of the field or property is not a collection type, then the type of the property or field must map to a schema simple type.

3.Validation for these statements from the spec. I'm getting feedback from Blaise on whether the second statement is invalid, since they conflict. An XML-bound class would be one that is in the JAXB context and not annotated with @XmlTransient.

*If the class, subClass, derives from another XML-bound class, baseClass directly or indirectly (other than java.lang.Object), then the subClass must not contain a mapped property or field annotated with @XmlValue annotation.

*The containing class must not extend another class (other than java.lang.Obect).
Comment 1 Paul Fullbright CLA 2011-11-16 12:11:17 EST
*** Bug 348288 has been marked as a duplicate of this bug. ***
Comment 2 Paul Fullbright CLA 2011-11-16 12:15:02 EST

*** This bug has been marked as a duplicate of bug 348288 ***