Package com.structurizr.configuration
Class WorkspaceConfiguration
java.lang.Object
com.structurizr.configuration.WorkspaceConfiguration
A wrapper for configuration options related to the workspace.
-
Method Summary
Modifier and TypeMethodDescriptionvoid
Adds a user.void
Adds a user, with the specified username and role.void
Clears all configured users.getScope()
Gets the scope of this workspacegetUsers()
Gets the set of users should have read-write or read-only access to the workspace.Gets the visibility of this workspace (private or public).void
setScope
(WorkspaceScope scope) Sets the workspace scope.void
setVisibility
(Visibility visibility) Sets the visibility of this workspace (private or public).
-
Method Details
-
getScope
Gets the scope of this workspace- Returns:
- a WorkspaceScope enum, or null if undefined
-
setScope
Sets the workspace scope.- Parameters:
scope
- a WorkspaceScope enum, or null if undefined
-
getVisibility
Gets the visibility of this workspace (private or public).- Returns:
- a Visibility enum
-
setVisibility
Sets the visibility of this workspace (private or public).- Parameters:
visibility
- a Visibility enum, or null to indicate that no changes should be made
-
getUsers
Gets the set of users should have read-write or read-only access to the workspace.- Returns:
- a Set of User objects (could be empty)
-
addUser
Adds a user.- Parameters:
user
- a User object representing the username and role
-
addUser
Adds a user, with the specified username and role.- Parameters:
username
- the username (e.g. an e-mail address)role
- the user's role
-
clearUsers
public void clearUsers()Clears all configured users.
-