org.ow2.jonas.naming
Interface JComponentContextFactory


public interface JComponentContextFactory

A JComponentContextFactory is a factory for JOnAS Component's Context.

Author:
Guillaume Sauthier
See Also:
org.ow2.jonas.lib.naming.ComponentContext

Method Summary
 void addDelegate(JComponentContextFactoryDelegate extension)
          Add the given JComponentContextFactoryDelegate to this NamingManager instance.
 Context createComponentContext(String id)
          Create Context for component environments.
 Context createComponentContext(String id, Context moduleContext, Context appContext)
          Create Context for component environments.
 void removeDelegate(JComponentContextFactoryDelegate extension)
          Remove the given JComponentContextFactoryDelegate from this NamingManager instance.
 

Method Detail

createComponentContext

Context createComponentContext(String id)
                               throws NamingException
Create Context for component environments. The returned context is a Java EE Component Context. It contains pre-defined references (according to the registered JComponentContextFactoryDelegate):

Parameters:
id - the Context ID.
Returns:
Naming Context for component environment
Throws:
NamingException - If exception encountered when creating namespace.

createComponentContext

Context createComponentContext(String id,
                               Context moduleContext,
                               Context appContext)
                               throws NamingException
Create Context for component environments. The returned context is a Java EE Component Context.

Parameters:
id - the Context ID.
moduleContext - the application context shared by all the components in a module
appContext - the application context shared by all the applications
Returns:
Naming Context for component environment
Throws:
NamingException - If exception encountered when creating namespace.

addDelegate

void addDelegate(JComponentContextFactoryDelegate extension)
                 throws NamingException
Add the given JComponentContextFactoryDelegate to this NamingManager instance.

Parameters:
extension - Added delegate
Throws:
NamingException - if the delegates is not added.

removeDelegate

void removeDelegate(JComponentContextFactoryDelegate extension)
                    throws NamingException
Remove the given JComponentContextFactoryDelegate from this NamingManager instance.

Parameters:
extension - Removed delegate
Throws:
NamingException - if the delegates is not removed.


Copyright © 2012 OW2 Consortium. All Rights Reserved.