org.eclipse.ecf.core.provider
Interface ISharedObjectInstantiator

All Known Implementing Classes:
ChannelFactory

public interface ISharedObjectInstantiator

Interface that must be implemented by extensions of the sharedObjectFactory extension point


Method Summary
 ISharedObject createInstance(SharedObjectTypeDescription typeDescription, java.lang.Class[] argTypes, java.lang.Object[] args)
          Create instance of ISharedObject.
 

Method Detail

createInstance

ISharedObject createInstance(SharedObjectTypeDescription typeDescription,
                             java.lang.Class[] argTypes,
                             java.lang.Object[] args)
                             throws SharedObjectCreateException
Create instance of ISharedObject. This is the interface that plugin implementations must implement for the sharedObjectFactory extension point. The caller may optionally specify both argument types and arguments that will be passed into this method (and therefore to the provider implementation implementing this method). For example:

SharedObjectFactory.getDefault().createSharedObject("foosharedobject",new String [] { java.lang.String }, new Object { "hello" });

Parameters:
typeDescription - the SharedObjectTypeDescription associated with the registered shared object provider implementation plugin
argTypes - the argument types specified by the caller. May be null if no arguments are passed in by caller to SharedObjectFactory.getDefault().createSharedObject(...)
args - arguments specified by the caller. May be null if no arguments are passed in by caller to SharedObjectFactory.getDefault().createSharedObject(...)
Returns:
ISharedObject instance. The provider implementation must return a valid object implementing ISharedObject OR throw a SharedObjectCreateException
Throws:
SharedObjectCreateException - TODO