Skip to main content

Notice: This Wiki is now read only and edits are no longer possible. Please see: https://gitlab.eclipse.org/eclipsefdn/helpdesk/-/wikis/Wiki-shutdown-plan for the plan.

Jump to: navigation, search

Dali/Indigo/JAXB 2.x/ProjectContent

< Dali‎ | Indigo‎ | JAXB 2.x
Revision as of 13:52, 5 October 2010 by Unnamed Poltroon (Talk)

Functional Specification: JAXB Project Content

[enter bug location here]

Document History

Date Author Version Description & Notes
10-5-2010 Paul Fullbright Draft

Feature overview

This feature is about determining the content of Dali JAXB projects.

Goals:

  • Add JAXB annotated classes to project content
  • Add JAXB annotated packages to project content
  • Add statically referenced classes to project content
  • Add user specified default annotated packages and classes to project content
  • Add support for jaxb.index
  • Add support for ObjectFactory classes
  • Add external packages and classes to project content

Concepts

Unlike JPA, the context of a JAXB 'project' (the JAXBContext) is determined dynamically at runtime, not dev-time. The user determines what is included when he creates the JAXBContext object. In addition, JAXB classes and packages do not have to be annotated - defaults abound! - so determining what classes are intended for JAXB use without having that information is tricky.

A user may pass in a list of packages, or a list of classes, or a combination. In addition to those packages and classes, any statically referenced classes are also brought in. (e.g. If Foo has a mapping to Bar, then Bar is also brought in, but if Foo is only extended by Bar, then it is not; it has no actual reference to Bar.)

When a package is passed in, a jaxb.index or ObjectFactory is used to determine the specific classes that are to be brought in. The jaxb.index is a return-separated list of classes. Any classes statically referenced by the ObjectFactory are brought in.

References

JAXBContext javadoc

Requirements / Functionality

JAXB annotated classes

Back to the top