|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.ow2.orchestra.pvm.env.Environment
org.ow2.orchestra.pvm.internal.env.BasicEnvironment
public class BasicEnvironment
| Field Summary | |
|---|---|
protected ClassLoader |
classLoader
|
protected Map<String,Context> |
contexts
|
protected String[] |
defaultSearchOrder
|
protected ArrayList<String> |
defaultSearchOrderList
|
protected Throwable |
exception
|
protected String |
userId
|
| Constructor Summary | |
|---|---|
BasicEnvironment()
|
|
| Method Summary | ||
|---|---|---|
void |
addContext(Context context)
|
|
void |
close()
closes the Environment by removing all its contexts. |
|
|
get(Class<T> type)
searches an object based on type. |
|
|
get(Class<T> type,
String[] searchOrder)
searches an object based on type. |
|
Object |
get(String name)
searches a named object in all the contexts in the default search order. |
|
Object |
get(String name,
String[] searchOrder)
searches a named object in all the contexts in the given search order. |
|
ClassLoader |
getClassLoader()
|
|
Context |
getContext(String contextName)
|
|
protected String[] |
getDefaultSearchOrder()
|
|
Context |
getEnvironmentContext()
|
|
Context |
getEnvironmentFactoryContext()
|
|
String |
getUserId()
get the authenticated user id |
|
void |
removeContext(Context context)
|
|
void |
setClassLoader(ClassLoader classLoader)
|
|
void |
setUserId(String userId)
set the authenticated user id |
|
| Methods inherited from class org.ow2.orchestra.pvm.env.Environment |
|---|
getCurrent, getFromCurrent, getFromCurrent, getFromCurrent, getFromCurrent, popEnvironment, pushEnvironment |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected String userId
protected Map<String,Context> contexts
protected ArrayList<String> defaultSearchOrderList
protected String[] defaultSearchOrder
protected Throwable exception
protected transient ClassLoader classLoader
| Constructor Detail |
|---|
public BasicEnvironment()
| Method Detail |
|---|
public Context getContext(String contextName)
getContext in class Environmentpublic void addContext(Context context)
addContext in class Environmentpublic void removeContext(Context context)
removeContext in class Environmentpublic Context getEnvironmentFactoryContext()
public Context getEnvironmentContext()
public String getUserId()
Environment
getUserId in class Environmentpublic void setUserId(String userId)
Environment
setUserId in class Environmentpublic ClassLoader getClassLoader()
getClassLoader in class Environmentpublic void setClassLoader(ClassLoader classLoader)
setClassLoader in class Environmentpublic Object get(String name)
Environment
get in class Environmentnull if
there is no object with the given name in the environment.
public Object get(String name,
String[] searchOrder)
Environment
get in class EnvironmentsearchOrder - list of contexts names. The object will be searched in these
contexts, in the given order.
null if
there is no object with the given name in the specified searchOrder
contexts.public <T> T get(Class<T> type)
Environment
get in class Environment
public <T> T get(Class<T> type,
String[] searchOrder)
Environment
get in class Environmentpublic void close()
Environment
close in class Environmentprotected String[] getDefaultSearchOrder()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||