Package org.restlet.engine.component
Class ComponentContext
- java.lang.Object
-
- org.restlet.Context
-
- org.restlet.engine.component.ComponentContext
-
public class ComponentContext extends Context
Context allowing access to the component's connectors.
-
-
Field Summary
Fields Modifier and Type Field Description private ComponentHelpercomponentHelperThe component helper.
-
Constructor Summary
Constructors Constructor Description ComponentContext(ComponentHelper componentHelper)Constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description ContextcreateChildContext()Creates a protected child context.protected ComponentHelpergetComponentHelper()Returns the component helper.protected voidsetComponentHelper(ComponentHelper componentHelper)Sets the component helper.-
Methods inherited from class org.restlet.Context
getAttributes, getClientDispatcher, getCurrent, getCurrentLogger, getDefaultEnroler, getDefaultVerifier, getExecutorService, getLogger, getParameters, getServerDispatcher, setAttributes, setClientDispatcher, setCurrent, setDefaultEnroler, setDefaultVerifier, setExecutorService, setLogger, setLogger, setParameters, setServerDispatcher
-
-
-
-
Field Detail
-
componentHelper
private volatile ComponentHelper componentHelper
The component helper.
-
-
Constructor Detail
-
ComponentContext
public ComponentContext(ComponentHelper componentHelper)
Constructor.- Parameters:
componentHelper- The component helper.
-
-
Method Detail
-
createChildContext
public Context createChildContext()
Description copied from class:ContextCreates a protected child context. This is especially useful for new application attached to their parent component, to ensure their isolation from the other applications. By default it creates a new context instance with empty or null properties, except the client and server dispatchers that are wrapped for isolation purpose.- Overrides:
createChildContextin classContext- Returns:
- The child context.
-
getComponentHelper
protected ComponentHelper getComponentHelper()
Returns the component helper.- Returns:
- The component helper.
-
setComponentHelper
protected void setComponentHelper(ComponentHelper componentHelper)
Sets the component helper.- Parameters:
componentHelper- The component helper.
-
-