Skip to main content

Notice: this Wiki will be going read only early in 2024 and edits will no longer be possible. Please see: https://gitlab.eclipse.org/eclipsefdn/helpdesk/-/wikis/Wiki-shutdown-plan for the plan.

Jump to: navigation, search

EclipseLink/Features/MOXy

< EclipseLink‎ | Features
Revision as of 12:55, 3 June 2008 by David.twelves.oracle.com (Talk | contribs) (Development status)

JAXB 2.0

Currently EclipseLink supports Java Architecture for XML Binding (JAXB) targeting the 2.0 specification. While the JAXB implementation within EclipseLink will not be fully compliant with the JAXB 2.1 specification in the 1.0 release it offers many of the core features, advanced features beyond the specification, and can address compliance through its inclusion of the reference implementation when needed.

Mapping Metadata

  • Majority of annotations
  • Generation of mapped domain model from XSD (Using JAXB RI's XJC)

Programmer's Interface

Extended Functionality

  • Externalize object-XML mapping using EclipseLink's Native XML configuration file
    • Path
    • Position
    • Inheritance
    • Transformations
    • Map support
    • Converter support for customer/extended types
  • Note: Support for all features of ClassDescriptor (TODO: Add link)
  • Pluggable parser support
  • Visual Mapping Workbench utility


Development status

TaskDependenciesOwning CommitterEstimateStatusBugzilla bugNotes
JAXB2.0
StAX Support: Marshalling, Unmarshalling Matt1.0M8: CompletedSupport is provided using Java Se 6 as the base platform. We can use javax.xml.transform.stax APIs to convert StAX events that we currently don't understand to SAX events which we do understand.
Annotation: XmlElementDeclNeeds primitive element support1.0M8: CompleteAn annotation that appears on ObjectFactory's factory methods and provides information about global elements from the schema. The type of these global elements can be either a simple type or a JAXB bound type. In either case, this element information needs to be processed and stored in order to be recognized when parsing an XML document. This ties in with the current primitive root element support that's being done in OXM
Annotation: XmlElementRef, XmlElementRefs Needs XmlElementDecl Matt15 daysTargetted for 1.0221867Annotations that are used to handle substitution groups in JAXB 2.0. The XmlElementRefs annotation can contain multiple XmlElementRef annotations. Support for this annotation will also require that we add support for JAXBElement/XMLRoot to be a child element and not just a root-level element since in the case that the XmlElementRef references something specified by an XmlElementDecl (as opposed to XmlRootElement) it must be wrapped in a JAXBElement
Annotation: XmlMixedNeeds XmlElementRef, XmlElementRefsMatt10 days1.0.1227413This annotation can be used in conjunction with an XmlAnyElement or XmlElementRef/XmlElementRefs annotation. It is used to indicate that mixed content is allowed for this complex-type
XMLConversionManager10 days1.0.1227414Provide additional support for javax.xml.datatype primitive classes
Notation5-10 days1.1227416If the XML document contains a value "prefix:name" then we need to convert this to a new javax.xml.namespace.QName(NAMESPACE_FOR_PREFIX, name) This could be done with a new NOTATION Mapping (2 weeks), OR by passing a NamespaceResolver into XMLConversionManager to be used when doing a conversion to QName (1 week)
DomHandler Matt15 daysCompletedDomHandler is used in conjunction with an XmlAnyElement mapping to specify a custom way that parts of an XML that are being unmarshalled are converted to a DOM representation. During an unmarshal operation; the binding layer first makes a call to get a Result object from the specified DomHandler. Then a portion of XML is sent to this result, and finally, the binding layer invokes a "getElement" method on the DomHandler to retrieve the XML DOM representation. During marshal, a marshal method must be invoked on the DomHandler that returns a Source. That source is then sent to the resulting XML document. This could possibly be implemented as a converter in the JAXB layer, or added into core OXM Support for this was added using a Converter on the XmlAnyCollectionMapping
Error Handling10 days1.1Currently the JAXB project and Schema generation will quietly fail in cases when exceptions should be thrown. For example, if an XmlAnyAttribute annotation appears on a non-map property, the JAXB generator will just ignore it rather than throw an exception. A lot of these cases will be uncovered by the TCK
JAXB2.1
Marshaller/Unmarshaller APIs5 daysCompletedAdd some new unmarshal/marshal APIs. The corresponding APIs should also be added to XMLUnmarshaller & XMLMarshaller if they are not already present https://jaxb.dev.java.net/issues/show_bug.cgi?id=221
Annotation: XmlSeeAlso5 days1.1227419This is a JAXB 2.1 annotation that simply gives a list of related classes. This is so a user can create a JAXBContext from a single class, and enumerate other classes that need to be bound through the use of this annotation. Typical use would be to enumerate the subclasses of a given class since that is a non-trivial task to do using reflection. Minimal work involved https://jaxb.dev.java.net/issues/show_bug.cgi?id=201
Annotation - XmlElementWrapperRequired5 days1.1227422Currently we only write out the grouping elements if leaf element is written out. We would need the option to always write the grouping element https://jaxb.dev.java.net/issues/show_bug.cgi?id=192
Annotation - XmlTransient on Class5 days1.1227425Allow @XmlTransient to be placed on a class, to indicate that it doesn't have the corresponding XML representation https://jaxb.dev.java.net/issues/show_bug.cgi?id=216

Back to the top