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.
Difference between revisions of "Dali/Indigo/JAXB 2.x/ProjectContent"
(New page: <div style="margin:5px;float:right;border:1px solid #000000;padding:5px">__TOC__</div> = Functional Specification: JAXB Project Content = [http://bugs.eclipse.org/238441 bug 238441] - pri...) |
|||
Line 2: | Line 2: | ||
= Functional Specification: JAXB Project Content = | = Functional Specification: JAXB Project Content = | ||
− | [ | + | [enter bug location here] |
== Document History == | == Document History == | ||
Line 16: | Line 16: | ||
|} | |} | ||
− | == | + | == Feature overview == |
This feature is about determining the content of Dali JAXB projects. | This feature is about determining the content of Dali JAXB projects. | ||
Line 23: | Line 23: | ||
* Add JAXB annotated classes to project content | * Add JAXB annotated classes to project content | ||
* Add JAXB annotated packages to project content | * Add JAXB annotated packages to project content | ||
− | * Add | + | * Add statically referenced classes to project content |
− | * Add specified | + | * Add user specified default annotated packages and classes to project content |
* Add support for jaxb.index | * Add support for jaxb.index | ||
* Add support for ObjectFactory classes | * Add support for ObjectFactory classes | ||
Line 31: | Line 31: | ||
== Concepts == | == Concepts == | ||
− | Unlike JPA, the context of a JAXB 'project' | + | 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.) | + | 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. | 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=== | ===References=== | ||
+ | |||
[http://download.oracle.com/javase/6/docs/api/javax/xml/bind/JAXBContext.html JAXBContext javadoc] | [http://download.oracle.com/javase/6/docs/api/javax/xml/bind/JAXBContext.html JAXBContext javadoc] | ||
Revision as of 13:52, 5 October 2010
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.