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., becauae 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 {
//...
}