prev table of contents next

6.2.6 Class Inclusion: XmlSeeAlso

The annotation XmlSeeAlso instructs JAXB to include the specified classes in the set of recognized classes, i.e., the ones that are bound to schema elements. The typical case where this is required is for the subclasses of some class that is included, in contrast to those classes that are statically referenced, e.g., because they are used as types for a field. You use XmlSeeAlso on some class, as shown in the example below:

@XmlSeeAlso( {Dog.class, Cat.class} )
class Animal {
   //...
}

prev table of contents next

Terms of Use; Privacy Policy; Copyright ©2008-2012 (revision 20120430.2938d5f)
 
 
Close
loading
Please Confirm
Close