Class ClassExtensionFactory
- java.lang.Object
-
- net.officefloor.plugin.managedobject.clazz.ClassExtensionFactory
-
- All Implemented Interfaces:
ExtensionFactory
public class ClassExtensionFactory extends java.lang.Object implements ExtensionFactory
ExtensionFactory
that return the object of theClassManagedObject
.This allows any implemented interfaces of the class to be an extension interface for the
ManagedObject
with implementation delegated to the object instantiated from the class.- Author:
- Daniel Sagenschneider
-
-
Constructor Summary
Constructors Constructor Description ClassExtensionFactory()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.Object
createExtension(ManagedObject managedObject)
Creates the specific extension for theManagedObject
.static void
registerExtension(AbstractAsyncManagedObjectSource.MetaDataContext<Indexed,Indexed> context, java.lang.Class<?> objectClass)
Registers the extension.
-
-
-
Method Detail
-
registerExtension
public static void registerExtension(AbstractAsyncManagedObjectSource.MetaDataContext<Indexed,Indexed> context, java.lang.Class<?> objectClass)
Registers the extension.- Parameters:
context
-AbstractAsyncManagedObjectSource.MetaDataContext
to add the extension interface.objectClass
- Object class which is the extension interface.
-
createExtension
public java.lang.Object createExtension(ManagedObject managedObject)
Description copied from interface:ExtensionFactory
Creates the specific extension for theManagedObject
.- Specified by:
createExtension
in interfaceExtensionFactory
- Parameters:
managedObject
-ManagedObject
that is have the extension created for it.- Returns:
- Extension for the
ManagedObject
.
-
-