public class RequestAttributeWorkspaceSelector extends DefaultWorkspaceSelector implements LogEnabled, Contextualizable
DefaultWorkspaceSelector using a context attribute for selecting
 the workspace.| Modifier and Type | Field and Description | 
|---|---|
private static String | 
__WORKSPACE_ATTRIBUTE  | 
private Context | 
_context  | 
private Logger | 
_logger  | 
_repositoryROLE| Constructor and Description | 
|---|
RequestAttributeWorkspaceSelector()  | 
| Modifier and Type | Method and Description | 
|---|---|
void | 
contextualize(Context context)  | 
void | 
enableLogging(Logger logger)  | 
static String | 
getForcedWorkspace(Request request)
Retrieves the workspace forced. 
 | 
String | 
getWorkspace()
Returns the current JCR workspace 
 | 
static void | 
setForcedWorkspace(Request request,
                  String workspaceName)
Forces the workspace to use. 
 | 
getWorkspaces, serviceprivate static final String __WORKSPACE_ATTRIBUTE
public RequestAttributeWorkspaceSelector()
public void contextualize(Context context) throws ContextException
contextualize in interface ContextualizableContextExceptionpublic void enableLogging(Logger logger)
enableLogging in interface LogEnabledpublic static void setForcedWorkspace(Request request, String workspaceName)
request - the current requestworkspaceName - the workspace name.public static String getForcedWorkspace(Request request)
request - the current requestnull for the default one.public String getWorkspace()
WorkspaceSelectorgetWorkspace in interface WorkspaceSelectorgetWorkspace in class DefaultWorkspaceSelector