public interface WorkbasketService
| Modifier and Type | Method and Description |
|---|---|
void |
checkAuthorization(String workbasketKey,
WorkbasketAuthorization authorization)
This method checks the authorization with the saved one for the actual User.
|
Workbasket |
createWorkbasket(Workbasket workbasket)
Create a new Workbasket.
|
WorkbasketAccessItem |
createWorkbasketAuthorization(WorkbasketAccessItem workbasketAccessItem)
Create and persist a new Workbasket Authorization with a Workbasket and a AccessId.
|
WorkbasketQuery |
createWorkbasketQuery()
This method provides a query builder for querying the database.
|
void |
deleteWorkbasketAuthorization(String id)
Deletes a specific authorization.
|
List<WorkbasketAccessItem> |
getAllAuthorizations()
Get all authorizations of the workbasket.
|
Workbasket |
getWorkbasket(String workbasketId)
Get Workbasket for a given id.
|
WorkbasketAccessItem |
getWorkbasketAuthorization(String id)
This method get one WorkbasketAccessItem with an id.
|
List<WorkbasketAccessItem> |
getWorkbasketAuthorizations(String workbasketKey)
Get all authorizations for a Workbasket.
|
Workbasket |
getWorkbasketByKey(String workbasketKey)
Get Workbasket for a given key.
|
List<Workbasket> |
getWorkbaskets()
Get all available Workbaskets.
|
List<Workbasket> |
getWorkbaskets(List<WorkbasketAuthorization> permission)
This method returns the workbaskets for which the current user has all permissions specified in the permissions
list.
|
Workbasket |
newWorkbasket()
Returns a new workbasket which is not persisted.
|
Workbasket |
updateWorkbasket(Workbasket workbasket)
Update a Workbasket.
|
WorkbasketAccessItem |
updateWorkbasketAuthorization(WorkbasketAccessItem workbasketAccessItem)
This method updates an Workbasket Authorization.
|
Workbasket getWorkbasket(String workbasketId) throws WorkbasketNotFoundException, InvalidWorkbasketException
workbasketId - the Id of the Workbasket requestedWorkbasketNotFoundException - If the Workbasket with workbasketId is not foundInvalidWorkbasketException - If required properties are missing in the found WorkbasketWorkbasket getWorkbasketByKey(String workbasketKey) throws WorkbasketNotFoundException, InvalidWorkbasketException
workbasketKey - the Key of the Workbasket requestedWorkbasketNotFoundException - If the Workbasket with workbasketId is not foundInvalidWorkbasketException - If required properties are missing in the found WorkbasketList<Workbasket> getWorkbaskets()
Workbasket createWorkbasket(Workbasket workbasket) throws InvalidWorkbasketException, WorkbasketNotFoundException
workbasket - The Workbasket to createInvalidWorkbasketException - If a required property of the Workbasket is not set.WorkbasketNotFoundException - If the to be created work basket references a distribution target that does not existWorkbasket updateWorkbasket(Workbasket workbasket) throws InvalidWorkbasketException, WorkbasketNotFoundException, NotAuthorizedException
workbasket - The Workbasket to updateInvalidWorkbasketException - if a required property of the workbasket is not setWorkbasketNotFoundException - if the updated work basket references a distribution target that does not existNotAuthorizedException - if the current user is not authorized to update the work basketWorkbasketAccessItem createWorkbasketAuthorization(WorkbasketAccessItem workbasketAccessItem)
workbasketAccessItem - the new workbasketAccessItemWorkbasketAccessItem updateWorkbasketAuthorization(WorkbasketAccessItem workbasketAccessItem)
workbasketAccessItem - the AuthorizationList<WorkbasketAccessItem> getAllAuthorizations()
void deleteWorkbasketAuthorization(String id)
id - the id of the WorbasketAccessItem to be deletedvoid checkAuthorization(String workbasketKey, WorkbasketAuthorization authorization) throws NotAuthorizedException
workbasketKey - the key of the workbasket we want to accessauthorization - the needed AuthorizationNotAuthorizedException - if the current user has not the requested authorization fot the specified workbasketWorkbasketAccessItem getWorkbasketAuthorization(String id)
id - the id of the requested WorkbasketAccessItemWorkbasketAccessItemList<WorkbasketAccessItem> getWorkbasketAuthorizations(String workbasketKey)
workbasketKey - the key of the WorkbasketList<Workbasket> getWorkbaskets(List<WorkbasketAuthorization> permission)
permission - a List of WorkbasketAuthorization enumsWorkbasketQuery createWorkbasketQuery()
WorkbasketQueryWorkbasket newWorkbasket()
Copyright © 2018. All rights reserved.