net.sf.jsefa.xml.annotation
Class XmlEntryPointFactory

java.lang.Object
  extended by net.sf.jsefa.xml.annotation.XmlEntryPointFactory

public final class XmlEntryPointFactory
extends Object

Factory for creating XmlEntryPoints from annotated classes.

Author:
Norman Lahme-Huetig

Constructor Summary
XmlEntryPointFactory(XmlTypeMappingFactory typeMappingFactory, ValidatorFactory validatorFactory)
          Constructs a new XmlEntryPointFactory.
 
Method Summary
 Collection<XmlEntryPoint> createEntryPoints(Class<?>... objectTypes)
          Creates entry points for the given object types and their descendants using their annotations.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

XmlEntryPointFactory

public XmlEntryPointFactory(XmlTypeMappingFactory typeMappingFactory,
                            ValidatorFactory validatorFactory)
Constructs a new XmlEntryPointFactory.

Parameters:
typeMappingFactory - the type mapping factory.
validatorFactory - the validator factory.
Method Detail

createEntryPoints

public Collection<XmlEntryPoint> createEntryPoints(Class<?>... objectTypes)
Creates entry points for the given object types and their descendants using their annotations.

The following rules apply:

1. For each two object types A and B in objectTypes with B being a descendant of A and A < B (A comes before B in objectTypes), the resulting list contains an entry point with an element name taken from B and not from A.

2. For each descendant B of an object type A in objectTypes the resulting list contains an entry point with an element name taken from A and not from B as long as rule 1 does not apply.

Parameters:
objectTypes - the object types
Returns:
a Collection of entry points.


Copyright © 2014. All rights reserved.