Package org.forgerock.services.context
Class RootContext
- java.lang.Object
-
- org.forgerock.services.context.AbstractContext
-
- org.forgerock.services.context.RootContext
-
- All Implemented Interfaces:
Context
public final class RootContext extends AbstractContext
AContext
which has an a globally unique ID but no parent. All request context chains are terminated by aRootContext
as the top-most context.
-
-
Field Summary
-
Fields inherited from class org.forgerock.services.context.AbstractContext
data
-
-
Constructor Summary
Constructors Constructor Description RootContext()
Construct a newRootContext
with the defaultIdGenerator
.RootContext(String id)
Construct a newRootContext
with the givenid
(uniqueness is not verified).RootContext(JsonValue savedContext, ClassLoader classLoader)
Restore from JSON representation.
-
Method Summary
-
Methods inherited from class org.forgerock.services.context.AbstractContext
as, asContext, containsContext, containsContext, get, getContext, getContextName, getId, getParent, getRootId, isRootContext, toJsonValue, toString
-
-
-
-
Constructor Detail
-
RootContext
public RootContext()
Construct a newRootContext
with the defaultIdGenerator
.- See Also:
IdGenerator.DEFAULT
-
RootContext
public RootContext(String id)
Construct a newRootContext
with the givenid
(uniqueness is not verified).- Parameters:
id
- context identifier (uniqueness is not verified, cannot benull
)
-
RootContext
public RootContext(JsonValue savedContext, ClassLoader classLoader)
Restore from JSON representation.- Parameters:
savedContext
- The JSON representation from which this context's attributes should be parsed.classLoader
- The ClassLoader which can properly resolve the persisted class-name.
-
-