Interface ScopeApi
public interface ScopeApi
Contains all api operations for handling scopes.
Scope defines a grouping of domains and communities that share same assignment.
-
Method Summary
Modifier and TypeMethodDescriptionaddScope
(AddScopeRequest request) Adds the scope basing on provided request.changeScope
(ChangeScopeRequest request) Changes the scope with the information that is present in the request.boolean
Returns true if a scope with given name exists.boolean
Returns true if a scope with given ID exists.Returns the list of all existing scopes.Returns the scope identified by given ID.getScopeByName
(String scopeName) Returns the scope with the given name.getScopeByPublicId
(String publicId) Returns the scope identified by the given public id.void
removeScope
(RemoveScopeRequest removeScopeRequest) Remove the scope identified by given RemoveScopeRequest.void
removeScope
(UUID scopeId) Remove the scope identified by given ID.
-
Method Details
-
addScope
Adds the scope basing on provided request.- Parameters:
request
- the properties of the scope to be added- Returns:
- the newly added scope
-
changeScope
Changes the scope with the information that is present in the request.- Parameters:
request
- changes to be performed on the scope- Returns:
- the changed scope
-
removeScope
Remove the scope identified by given ID.- Parameters:
scopeId
- the ID of the scope
-
removeScope
Remove the scope identified by given RemoveScopeRequest.- Parameters:
removeScopeRequest
- the remove scope requests
-
getScope
Returns the scope identified by given ID.- Parameters:
scopeId
- the ID of the scope- Returns:
- the found scope
-
getScopeByPublicId
Returns the scope identified by the given public id.- Parameters:
publicId
- the public id of the scope- Returns:
- the found scope
-
exists
Returns true if a scope with given ID exists.- Parameters:
scopeId
- the ID of the scope- Returns:
- true if a scope with given ID exists,
false
otherwise
-
getAllScopes
@SecurityAuditMethod(resultFormatter=com.collibra.audit.formatter.CollectionCountFormatter.class) List<Scope> getAllScopes()Returns the list of all existing scopes.- Returns:
- the list of all scopes
-
getScopeByName
Returns the scope with the given name.- Parameters:
scopeName
- the name of the scope- Returns:
- the found scope
- Throws:
ApiEntityNotFoundException
- if the scope could not be found
-
exists
Returns true if a scope with given name exists.- Parameters:
scopeName
- the name of the scope- Returns:
true
if a scope with given name exists,false
otherwise
-