Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 336259 - [Validation] @XmlList validation enhancements
Summary: [Validation] @XmlList validation enhancements
Status: RESOLVED FIXED
Alias: None
Product: Dali JPA Tools
Classification: WebTools
Component: JAXB (show other bugs)
Version: 3.0   Edit
Hardware: PC Windows XP
: P3 enhancement (vote)
Target Milestone: 3.1 M3   Edit
Assignee: Paul Fullbright CLA
QA Contact:
URL:
Whiteboard:
Keywords: plan
Depends on:
Blocks:
 
Reported: 2011-02-03 11:44 EST by Karen Butzke CLA
Modified: 2011-10-31 11:01 EDT (History)
2 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Karen Butzke CLA 2011-02-03 11:44:22 EST
XmlList model support was added in bug 326718. 1 validation error that we need is that the attribute must map to a simple type. Examples from the JAXB spec:

// Examples: Legal usage of @XmlList
@XmlList List<Integer> foo; // int maps to xs:int
@XmlList String[] foo; // String maps to xs:string
@XmlList List<Bar> foo; // only if Bar maps to a simple type


// Example: Illegal usage of @XmlList
public class Foo {
    // @XmlValue maps List to a XML Schema list simple type
    @XmlValue List<Integer> a;
}
class Bar {
    // Use of @XmlList is illegal since Foo itself mapped
    // to a XML Schema list simple type; XML Schema list simple
    // type can't derive from another XML Schema list simple type
    @XmlList List<Foo> y;
}
Comment 1 Paul Fullbright CLA 2011-10-27 18:31:24 EDT
Added for 3.1 M3.