public class WorkspaceProviderImpl extends Object implements WorkspaceProvider
Modifier and Type | Field and Description |
---|---|
private WorkspaceImpl |
currentWorkspace |
private ProjectImpl |
project |
private List<Workspace> |
workspaces |
Constructor and Description |
---|
WorkspaceProviderImpl(ProjectImpl project) |
Modifier and Type | Method and Description |
---|---|
void |
addWorkspace(Workspace workspace) |
WorkspaceImpl |
getCurrentWorkspace()
Returns the current workspace or null if none.
|
Workspace |
getPrecedingWorkspace(Workspace workspace) |
Workspace |
getWorkspace(int id)
Retrieve a workspace based on its unique identifier.
|
Workspace[] |
getWorkspaces()
Returns all the workspaces.
|
boolean |
hasCurrentWorkspace()
Returns true if the project has a current workspace.
|
WorkspaceImpl |
newWorkspace() |
WorkspaceImpl |
newWorkspace(int id) |
void |
removeWorkspace(Workspace workspace) |
void |
setCurrentWorkspace(Workspace currentWorkspace) |
private transient WorkspaceImpl currentWorkspace
private final transient ProjectImpl project
public WorkspaceProviderImpl(ProjectImpl project)
public WorkspaceImpl newWorkspace()
public WorkspaceImpl newWorkspace(int id)
public void addWorkspace(Workspace workspace)
public void removeWorkspace(Workspace workspace)
public WorkspaceImpl getCurrentWorkspace()
WorkspaceProvider
getCurrentWorkspace
in interface WorkspaceProvider
public Workspace[] getWorkspaces()
WorkspaceProvider
Returns an empty array if no workspaces.
getWorkspaces
in interface WorkspaceProvider
public Workspace getWorkspace(int id)
WorkspaceProvider
getWorkspace
in interface WorkspaceProvider
id
- workspace's unique identifierpublic void setCurrentWorkspace(Workspace currentWorkspace)
public boolean hasCurrentWorkspace()
WorkspaceProvider
hasCurrentWorkspace
in interface WorkspaceProvider
Copyright © 2007–2016 Gephi Consortium. All rights reserved.