Community
Participate
Working Groups
We need to add support for configuring XMLTransformationMappings via external metadata. The schema component should look something like the folllowing: <xs:element name="xml-transformation" substitutionGroup="java-attribute"> <xs:complexType> <xs:complexContent> <xs:extension base="java-attribute"> <xs:all> <xs:element name="xml-read-transformer"> <xs:complexType> <xs:attribute name="transformer-class" type="xs:string" /> <xs:attribute name="method" type="xs:string" /> </xs:complexType> </xs:element> <xs:element name="xml-write-transformer" minOccurs="0" maxOccurs="unbounded"> <xs:complexType> <xs:attribute name="xml-path" type="xs:string" /> <xs:attribute name="transformer-class" type="xs:string" /> <xs:attribute name="method" type="xs:string" /> </xs:complexType> </xs:element> <xs:element name="xml-property" type="xml-property" minOccurs="0" maxOccurs="unbounded"/> <xs:element name="xml-access-methods" type="xml-access-methods" minOccurs="0"/> </xs:all> <xs:attribute name="name" type="xs:string" use="required"/> <xs:attribute name="optional" type="xs:boolean" default="false"/> <xs:attribute name="xml-accessor-type" type="xml-access-type" minOccurs="0" default="PUBLIC_MEMBER"/> <xs:attribute name="mutable" type="xs:boolean" default="false"/> <xs:attribute name="attribute-type" type="xs:string" /> </xs:extension> </xs:complexContent> </xs:complexType> </xs:element> Design and expected usage can be found here: http://wiki.eclipse.org/EclipseLink/DesignDocs/317962/Phase2.1#xml-transformation
Created attachment 176393 [details] Contains proposed fix + supporting test cases
Created attachment 176492 [details] Contains proposed fix + supporting test cases
Created attachment 176696 [details] Contains proposed fix + supporting test cases Made changes based on review.
Final XSD change: <xs:element name="xml-transformation" substitutionGroup="java-attribute"> <xs:complexType> <xs:complexContent> <xs:extension base="java-attribute"> <xs:sequence> <xs:element name="xml-access-methods" type="xml-access-methods" minOccurs="0"/> <xs:element ref="xml-properties" minOccurs="0"/> <xs:element name="xml-read-transformer"> <xs:complexType> <xs:attribute name="method" type="xs:string" /> <xs:attribute name="transformer-class" type="xs:string" /> </xs:complexType> </xs:element> <xs:element name="xml-write-transformer" minOccurs="0" maxOccurs="unbounded"> <xs:complexType> <xs:attribute name="method" type="xs:string" /> <xs:attribute name="xml-path" type="xs:string" /> <xs:attribute name="transformer-class" type="xs:string" /> </xs:complexType> </xs:element> </xs:sequence> <xs:attribute name="optional" type="xs:boolean" default="false"/> </xs:extension> </xs:complexContent> </xs:complexType> </xs:element>
Reviewed by: matt.macivor@oracle.com Tests: all unit tests pass as expected; jaxb/externalizedmetadata/mappings/xmltransformation/XmlTransformationTestCases
The Eclipselink project has moved to Github: https://github.com/eclipse-ee4j/eclipselink