Class DefaultWorkspaceManager
- java.lang.Object
-
- com.marklogic.client.ext.helper.LoggingObject
-
- com.marklogic.client.ext.qconsole.impl.DefaultWorkspaceManager
-
- All Implemented Interfaces:
WorkspaceManager
public class DefaultWorkspaceManager extends LoggingObject implements WorkspaceManager
Default implementation that uses the ML Java Client API to manage workspaces. By default, workspaces will be exported and imported to/from ~/.qconsole/workspaces/(ML username). This can be overridden by calling setBaseDir.
-
-
Field Summary
-
Fields inherited from class com.marklogic.client.ext.helper.LoggingObject
logger
-
-
Constructor Summary
Constructors Constructor Description DefaultWorkspaceManager(com.marklogic.client.DatabaseClient client)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected java.lang.StringdetermineImportScriptToUse()java.util.List<java.io.File>exportWorkspaces(java.lang.String user, java.lang.String... workspaceNames)protected java.io.FilegetDefaultWorkspacesDir()java.util.List<java.io.File>importWorkspaces(java.lang.String user, java.lang.String... workspaceNames)voidsetBaseDir(java.io.File baseDir)-
Methods inherited from class com.marklogic.client.ext.helper.LoggingObject
format
-
-
-
-
Method Detail
-
exportWorkspaces
public java.util.List<java.io.File> exportWorkspaces(java.lang.String user, java.lang.String... workspaceNames)- Specified by:
exportWorkspacesin interfaceWorkspaceManager- Returns:
- a list of files that workspaces for the given user were exported to
-
importWorkspaces
public java.util.List<java.io.File> importWorkspaces(java.lang.String user, java.lang.String... workspaceNames)- Specified by:
importWorkspacesin interfaceWorkspaceManager- Returns:
- a list of files that workspaces for the given user were imported from
-
determineImportScriptToUse
protected java.lang.String determineImportScriptToUse()
-
getDefaultWorkspacesDir
protected java.io.File getDefaultWorkspacesDir()
- Returns:
- defaults to ~/.qconsole/workspaces
-
setBaseDir
public void setBaseDir(java.io.File baseDir)
-
-