public interface WorkspacePlugin extends ExecContextPlugin
| Modifier and Type | Interface and Description |
|---|---|
static class |
WorkspacePlugin.GetWorkspaceDirMode
Enumerates the modes when obtaining a
WorkspaceDir. |
static class |
WorkspacePlugin.WorkspaceDirAccessMode
Enumerates the possible Workspace directory access modes for the
getWorkspaceDir method.
|
| Modifier and Type | Method and Description |
|---|---|
void |
deleteWorkspaceDir(WorkspaceDir workspaceDir)
Deletes a
WorkspaceDir and its corresponding path, if it exists. |
Path |
getPathWorkspace() |
Set<WorkspaceDir> |
getSetWorkspaceDir(Class<? extends WorkspaceDir> workspaceDirClass)
Returns the Set of all
WorkspaceDir's of a given WorkspaceDir
subclass. |
Set<WorkspaceDir> |
getSetWorkspaceDir(WorkspaceDir workspaceDirIncomplete)
Returns the Set of all
WorkspaceDir's matching some potentially
incomplete WorkspaceDir definition. |
Path |
getWorkspaceDir(WorkspaceDir workspaceDir,
EnumSet<WorkspacePlugin.GetWorkspaceDirMode> enumSetGetWorkspaceDirMode,
WorkspacePlugin.WorkspaceDirAccessMode workspaceDirAccessMode)
Returns the Path corresponding to the
WorkspaceDir. |
WorkspacePlugin.WorkspaceDirAccessMode |
getWorkspaceDirAccessMode(Path pathWorkspaceDir)
Gets the current
WorkspacePlugin.WorkspaceDirAccessMode for a WorkspaceDir
given its Path. |
WorkspaceDir |
getWorkspaceDirConflict(WorkspaceDir workspaceDir)
Returns a conflicting
WorkspaceDir with a given WorkspaceDir or null if
none. |
WorkspaceDir |
getWorkspaceDirFromPath(Path pathWorkspaceDir)
Returns a
WorkspaceDir given its Path. |
boolean |
isPathWorkspaceDirExists(Path pathWorkspaceDir)
Verifies if a
WorkspaceDir exists given its Path. |
boolean |
isSupportMultipleModuleVersion() |
boolean |
isWorkspaceDirExist(WorkspaceDir workspaceDir)
Verifies if a
WorkspaceDir exists. |
void |
releaseWorkspaceDir(Path pathWorkspaceDir)
Releases a
WorkspaceDir given it corresponding Path. |
void |
updateWorkspaceDir(WorkspaceDir workspaceDir,
WorkspaceDir workspaceDirNew)
Updates a
WorkspaceDir. |
Path getPathWorkspace()
boolean isSupportMultipleModuleVersion()
boolean isWorkspaceDirExist(WorkspaceDir workspaceDir)
WorkspaceDir exists.
The path to the WorkspaceDir may or may not exist. Only the knowledge of the WorkspaceDir within the workspace is verified.
workspaceDir - WorkspaceDir.WorkspaceDir getWorkspaceDirConflict(WorkspaceDir workspaceDir)
WorkspaceDir with a given WorkspaceDir or null if
none.
A conflicting WorkspaceDir is one which maps to the same path.
If isSupportMultipleModuleVersion() and the specified WorkspaceDir is
for the same Module but a different Version, null should be
returned.
If it is for a different Module which would map to the same path as an existing WorkspaceDir, that WorkspaceDir should be returned.
workspaceDir - WorkspaceDir.Path getWorkspaceDir(WorkspaceDir workspaceDir, EnumSet<WorkspacePlugin.GetWorkspaceDirMode> enumSetGetWorkspaceDirMode, WorkspacePlugin.WorkspaceDirAccessMode workspaceDirAccessMode)
WorkspaceDir.
Null cannot be returned. An exception is raised if thw WorkspaceDir does not exist or cannot be created.
The WorkspaceDir must be released with releaseWorkspaceDir(java.nio.file.Path) unless
WorkspacePlugin.WorkspaceDirAccessMode.PEEK was specified.
workspaceDir - WorkspaceDir.enumSetGetWorkspaceDirMode - EnumSet of GetWorkspaceDirMode.workspaceDirAccessMode - WorkspaceDirAccessMode.void releaseWorkspaceDir(Path pathWorkspaceDir)
WorkspaceDir given it corresponding Path.
The WorkspaceDir must have been obtained with getWorkspaceDir(org.azyva.dragom.execcontext.plugin.WorkspaceDir, java.util.EnumSet<org.azyva.dragom.execcontext.plugin.WorkspacePlugin.GetWorkspaceDirMode>, org.azyva.dragom.execcontext.plugin.WorkspacePlugin.WorkspaceDirAccessMode).
pathWorkspaceDir - Path to the WorkspaceDir.WorkspacePlugin.WorkspaceDirAccessMode getWorkspaceDirAccessMode(Path pathWorkspaceDir)
WorkspacePlugin.WorkspaceDirAccessMode for a WorkspaceDir
given its Path.pathWorkspaceDir - Path to the WorkspaceDir.void updateWorkspaceDir(WorkspaceDir workspaceDir, WorkspaceDir workspaceDirNew)
WorkspaceDir.
To be used when the ModuleVersion within the path corresponding to
a WorkspaceDir is changed.
The WorkspaceDir must be accessed for
WorkspacePlugin.WorkspaceDirAccessMode.READ_WRITE.
workspaceDir - Current WorkspaceDir.workspaceDirNew - New WorkspaceDir.void deleteWorkspaceDir(WorkspaceDir workspaceDir)
WorkspaceDir and its corresponding path, if it exists.
The WorkspaceDir must be accessed for
WorkspacePlugin.WorkspaceDirAccessMode.READ_WRITE.
workspaceDir - WorkspaceDir.Set<WorkspaceDir> getSetWorkspaceDir(Class<? extends WorkspaceDir> workspaceDirClass)
WorkspaceDir's of a given WorkspaceDir
subclass.workspaceDirClass - WorkspaceDir subclass. Can be null to return all
WorkspaceDir.Set<WorkspaceDir> getSetWorkspaceDir(WorkspaceDir workspaceDirIncomplete)
WorkspaceDir's matching some potentially
incomplete WorkspaceDir definition.
An example of an incomplete WorkspaceDir definition is a
WorkspaceDirUserModuleVersion with a null Version.
workspaceDirIncomplete - Incomplete WorkspaceDir.boolean isPathWorkspaceDirExists(Path pathWorkspaceDir)
WorkspaceDir exists given its Path.pathWorkspaceDir - Path to the WorkspaceDir.WorkspaceDir getWorkspaceDirFromPath(Path pathWorkspaceDir)
WorkspaceDir given its Path.
Useful for a method that has a hold on the path of a WorkspaceDir and needs to know the corresponding WorkspaceDir.
pathWorkspaceDir - Path to the WorkspaceDir.Copyright © 2015–2017 AZYVA INC.. All rights reserved.