|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.aurorasoftworks.signal.runtime.core.context.Context
public class Context
A default implementation of the IContext
interface.
This class is thread-safe.
Constructor Summary | |
---|---|
Context()
Creates a new Context instance. |
Method Summary | |
---|---|
boolean |
containsBean(java.lang.String name)
Determines whether a bean with the specified name already exists. |
protected void |
doRegisterBean(java.lang.String name,
java.lang.Object bean)
|
java.lang.Object |
getBean(java.lang.Class beanClass)
|
java.lang.Object |
getBean(java.lang.String name)
Retrieves a bean previously registered with the specified name. |
java.util.Vector |
getBeanNames(java.lang.Class beanClass)
Returns names of the beans of the specified type |
protected IBeanReference |
getBeanReference(java.lang.String name)
|
java.util.Vector |
getBeans(java.lang.Class beanClass)
|
static IProxyFactory |
getDefaultProxyFactory()
|
IProxyFactory |
getProxyFactory()
|
protected void |
processBean(IBeanReference ref,
java.lang.Object processedResult)
Handles a bean or a bean reference returned by a IBeanProcessor . |
java.lang.Object |
processLazyBean(java.lang.Object processedResult)
|
void |
registerBean(java.lang.String name,
java.lang.Object bean)
Registers a bean using the provided name. |
protected void |
registerBeanReference(IBeanReference ref)
Registers a bean reference. |
static void |
setDefaultProxyFactory(IProxyFactory defaultProxyFactory)
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public Context()
Context
instance.
Method Detail |
---|
public static IProxyFactory getDefaultProxyFactory()
public static void setDefaultProxyFactory(IProxyFactory defaultProxyFactory)
public boolean containsBean(java.lang.String name)
containsBean
in interface IContext
name
- a name of a bean to be located in the context
public java.lang.Object getBean(java.lang.String name) throws ContextException
getBean
in interface IContext
name
- name of a bean to be retrieved
ContextException
protected IBeanReference getBeanReference(java.lang.String name)
public java.util.Vector getBeanNames(java.lang.Class beanClass) throws ContextException
getBeanNames
in interface IContext
ContextException
public java.util.Vector getBeans(java.lang.Class beanClass) throws ContextException
getBeans
in interface IContext
ContextException
public java.lang.Object getBean(java.lang.Class beanClass) throws ContextException
getBean
in interface IContext
ContextException
public java.lang.Object processLazyBean(java.lang.Object processedResult) throws ContextException
ContextException
protected void processBean(IBeanReference ref, java.lang.Object processedResult) throws ContextException
IBeanProcessor
.
ref
- a bean reference passed to
a IBeanProcessor
processedResult
- a result returned by a IBeanProcessor
(a bean or a IBeanReference
object)
ContextException
- if an error is encountered while registering
a new bean or a new bean referencepublic void registerBean(java.lang.String name, java.lang.Object bean) throws ContextException
registerBean
in interface IContext
name
- a name of the bean being registeredbean
- a bean to be registered
ContextException
protected void doRegisterBean(java.lang.String name, java.lang.Object bean) throws ContextException
ContextException
protected void registerBeanReference(IBeanReference ref) throws ContextException
IBeanReference
for more information.
ref
- a bean reference to be registered
ContextException
public IProxyFactory getProxyFactory()
getProxyFactory
in interface IContext
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |