org.eclipse.higgins.idas.api
Interface IContextFactory

All Superinterfaces:
org.eclipse.higgins.configuration.api.IConfigurableComponent

public interface IContextFactory
extends org.eclipse.higgins.configuration.api.IConfigurableComponent

As defined at http://spwiki.editme.com/ContextProvider#ContextFactory, This interface is implemented by IdAS context providers so that their IContext instances may be instantiated.

TODO (Arch)(Doc): Talk about what's required to make this work -- how factories are registered and referenced in the Higgins system.

TODO (Doc): Finish commenting methods.


Method Summary
 IContext createContext(IContextId contextID)
          Using a context ID, creates an instance of IContext and returns it.
 org.eclipse.higgins.configuration.api.ISettingDescriptor getContextDescriptor(String contextIdName)
          Returns the setting descriptor for a given context Id.
 Iterator getContexts(String filter)
           
 String getName()
           
 String getPolicy()
          Returns the policy in effect for this Context Factory.
 List getTypes()
          Returns the context types supported by this context factory.
 void setPolicy(String policy)
          Sets the policy for for this Context Factory.
 
Methods inherited from interface org.eclipse.higgins.configuration.api.IConfigurableComponent
configure, getComponentDescriptor
 

Method Detail

getName

String getName()
               throws IdASException
Throws:
IdASException

getTypes

List getTypes()
              throws IdASException
Returns the context types supported by this context factory.

Returns:
List of context types.
Throws:
IdASException

getContexts

Iterator getContexts(String filter)
                     throws IdASException
Parameters:
filter - Format TBD
Returns:
An Iterator of URIs. The set of Context References of Contexts which have been created by this Context Factory
Throws:
IdASException

createContext

IContext createContext(IContextId contextID)
                       throws IdASException
Using a context ID, creates an instance of IContext and returns it.

Parameters:
contextID - context ID specifying the Context to create.
Returns:
An IContext instance appropriate for the context ID.
Throws:
IdASException

getPolicy

String getPolicy()
                 throws IdASException
Returns the policy in effect for this Context Factory.

Returns:
Format is WS-Policy / WS-SecurityPolicy

Throws:
IdASException - TODO (Arch)(Doc): Describe format in more detail. Give examples.

setPolicy

void setPolicy(String policy)
               throws IdASException
Sets the policy for for this Context Factory.

Parameters:
policy - Format is WS-Policy / WS-SecurityPolicy

Throws:
IdASException - TODO (Arch)(Doc): Describe format in more detail. Give examples.

getContextDescriptor

org.eclipse.higgins.configuration.api.ISettingDescriptor getContextDescriptor(String contextIdName)
                                                                              throws IdASException
Returns the setting descriptor for a given context Id. A typical use case would be an IdAS application getting a handle to the context factory based on the type of context to create and then using this API to get the setting descriptors for a context id to be created based on this factory.

Parameters:
contextIdName -
Returns:
The setting descriptor for a context id based on this context factory
Throws:
IdASException