Interface ISharedObjectFactory
- 
- All Known Implementing Classes:
- SharedObjectFactory
 
 public interface ISharedObjectFactoryContainer factory contractSharedObjectFactoryfor default implementation.
- 
- 
Method SummaryAll Methods Instance Methods Abstract Methods Modifier and Type Method Description SharedObjectTypeDescriptionaddDescription(SharedObjectTypeDescription description)booleancontainsDescription(SharedObjectTypeDescription description)Check to see if a given named description is already contained by this factoryISharedObjectcreateSharedObject(String descriptionName)Create ISharedObject instance.ISharedObjectcreateSharedObject(String descriptionName, Object[] args)Create ISharedObject instance.ISharedObjectcreateSharedObject(SharedObjectTypeDescription typeDescription, Object[] args)Create ISharedObject instance.SharedObjectTypeDescriptiongetDescriptionByName(String name)Get the known SharedObjectTypeDescription given it's name.ListgetDescriptions()Get a collection of the SharedObjectTypeDescriptions currently known to this factory.SharedObjectTypeDescriptionremoveDescription(SharedObjectTypeDescription scd)Remove given description from set known to this factory.
 
- 
- 
- 
Method Detail- 
addDescriptionSharedObjectTypeDescription addDescription(SharedObjectTypeDescription description) 
 - 
getDescriptionsList getDescriptions() Get a collection of the SharedObjectTypeDescriptions currently known to this factory. This allows clients to query the factory to determine what if any other SharedObjectTypeDescriptions are currently registered with the factory, and if so, what they are.- Returns:
- List of SharedObjectTypeDescription instances. Will not be null.
 
 - 
containsDescriptionboolean containsDescription(SharedObjectTypeDescription description) Check to see if a given named description is already contained by this factory- Parameters:
- description- the SharedObjectTypeDescription to look for
- Returns:
- true if description is already known to factory, false otherwise
 
 - 
getDescriptionByNameSharedObjectTypeDescription getDescriptionByName(String name) throws SharedObjectCreateException Get the known SharedObjectTypeDescription given it's name.- Parameters:
- name-
- Returns:
- SharedObjectTypeDescription found. Null if description not found.
- Throws:
- SharedObjectCreateException
 
 - 
createSharedObjectISharedObject createSharedObject(SharedObjectTypeDescription typeDescription, Object[] args) throws SharedObjectCreateException Create ISharedObject instance. Given a SharedObjectTypeDescription object, a String [] of argument types, and an Object [] of parameters, this method will- lookup the known SharedObjectTypeDescriptions to find one of matching name
- if found, will retrieve or create an ISharedObjectInstantiator for that description
- Call the ISharedObjectInstantiator.createInstance method to return an instance of ISharedObject
 - Parameters:
- typeDescription- the SharedObjectTypeDescription to use to create the instance
- args- an Object [] of arguments passed to the createInstance method of the ISharedObjectInstantiator
- Returns:
- a valid instance of ISharedObject. Will not be null.
- Throws:
- SharedObjectCreateException- if shared object cannot be created
 
 - 
createSharedObjectISharedObject createSharedObject(String descriptionName) throws SharedObjectCreateException Create ISharedObject instance. Given a SharedObjectTypeDescription name, this method will- lookup the known SharedObjectTypeDescriptions to find one of matching name
- if found, will retrieve or create an ISharedObjectInstantiator for that description
- Call the ISharedObjectInstantiator.createInstance method to return an instance of ISharedObject
 - Parameters:
- descriptionName- the SharedObjectTypeDescription name to lookup
- Returns:
- a valid instance of ISharedObject. Will not be null.
- Throws:
- SharedObjectCreateException
 
 - 
createSharedObjectISharedObject createSharedObject(String descriptionName, Object[] args) throws SharedObjectCreateException Create ISharedObject instance. Given a SharedObjectTypeDescription name, this method will- lookup the known SharedObjectTypeDescriptions to find one of matching name
- if found, will retrieve or create an ISharedObjectInstantiator for that description
- Call the ISharedObjectInstantiator.createInstance method to return an instance of ISharedObject
 - Parameters:
- descriptionName- the SharedObjectTypeDescription name to lookup
- args- the Object [] of arguments passed to the ISharedObjectInstantiator.createInstance method
- Returns:
- a valid instance of IContainer. Will not be null.
- Throws:
- SharedObjectCreateException
 
 - 
removeDescriptionSharedObjectTypeDescription removeDescription(SharedObjectTypeDescription scd) Remove given description from set known to this factory.- Parameters:
- scd- the SharedObjectTypeDescription to remove
- Returns:
- the removed SharedObjectTypeDescription, null if nothing removed
 
 
- 
 
-