Package org.jfree.xml.factory.objects
Class ClassFactoryImpl
java.lang.Object
org.jfree.xml.factory.objects.ClassFactoryImpl
- All Implemented Interfaces:
Serializable,ClassFactory
- Direct Known Subclasses:
ClassFactoryCollector,JavaBaseClassFactory,URLClassFactory
An abstract class that implements the
ClassFactory interface.- Author:
- Thomas Morgner.
- See Also:
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidconfigure(Configuration config) Configures this factory.booleanTests for equality.Returns the class comparator used to sort the super classes of an object.Returns the currently set configuration or null, if none was set.Returns an object-description for a class.Returns an iterator that provides access to the registered object definitions.getSuperClassObjectDescription(Class d, ObjectDescription knownSuperClass) Returns the most concrete object-description for the super class of a class.inthashCode()Returns a hash code.protected voidregisterClass(Class key, ObjectDescription od) Registers an object description with the factory.
-
Constructor Details
-
ClassFactoryImpl
public ClassFactoryImpl()Creates a new class factory.
-
-
Method Details
-
getComparator
Returns the class comparator used to sort the super classes of an object.- Returns:
- the class comparator.
-
getDescriptionForClass
Returns an object-description for a class.- Specified by:
getDescriptionForClassin interfaceClassFactory- Parameters:
c- the class.- Returns:
- An object description.
-
getSuperClassObjectDescription
Returns the most concrete object-description for the super class of a class.- Specified by:
getSuperClassObjectDescriptionin interfaceClassFactory- Parameters:
d- the class.knownSuperClass- a known supported superclass or null, if no superclass is known yet.- Returns:
- The object description.
-
registerClass
Registers an object description with the factory.- Parameters:
key- the key.od- the object description.
-
getRegisteredClasses
Returns an iterator that provides access to the registered object definitions.- Specified by:
getRegisteredClassesin interfaceClassFactory- Returns:
- The iterator.
-
configure
Configures this factory. The configuration contains several keys and their defined values. The given reference to the configuration object will remain valid until the report parsing or writing ends.The configuration contents may change during the reporting.
- Specified by:
configurein interfaceClassFactory- Parameters:
config- the configuration, never null
-
getConfig
Returns the currently set configuration or null, if none was set.- Returns:
- the configuration.
-
equals
Tests for equality.- Specified by:
equalsin interfaceClassFactory- Overrides:
equalsin classObject- Parameters:
o- the object to test.- Returns:
- A boolean.
-
hashCode
Returns a hash code.- Specified by:
hashCodein interfaceClassFactory- Overrides:
hashCodein classObject- Returns:
- A hash code.
-