Interface TodoProducerChecklistAssignmentSession
- All Superinterfaces:
AutoCloseable, Closeable, OsidSession, OsidSession
This session provides methods to re-assign TodoProducer to
Checklist mappings. A TodoProducer may appear in multiple
Checklist objects and removing the last reference to a
TodoProducer is the equivalent of deleting it. Each Checklist may
have its own authorizations governing who is allowed to operate on it.
Adding a reference of a TodoProducer to another
Checklist is not a copy operation (eg: does not change its Id ).
-
Method Summary
Modifier and TypeMethodDescriptionvoidassignTodoProducerToChecklist(Id todoProducerId, Id checklistId) Adds an existingTodoProducerto anChecklist.booleanTests if this user can alter todo producer/checklist mappings.booleancanAssignTodoProducersToChecklist(Id checklistId) Tests if this user can alter todo producer/checklist mappings.getAssignableChecklistIds(Id checklistId) Gets a list of checklists including and under the given checklist node in which any todo producer can be assigned.getAssignableChecklistIdsForTodoProducer(Id checklistId, Id todoProducerId) Gets a list of checklists including and under the given checklist node in which a specific todo producer can be assigned.voidreassignTodoProducerToChecklist(Id todoProducerId, Id fromChecklistId, Id toChecklistId) Moves aTodoProducerfrom oneChecklistto another.voidunassignTodoProducerFromChecklist(Id todoProducerId, Id checklistId) Removes aTodoProducerfrom anChecklist.Methods inherited from interface OsidSession
closeMethods inherited from interface OsidSession
getAuthenticatedAgent, getAuthenticatedAgentId, getClockRate, getDate, getEffectiveAgent, getEffectiveAgentId, getFormatType, getLocale, isAuthenticated, startTransaction, supportsTransactionsModifier and TypeMethodDescriptionGets the agent authenticated to this session.Gets theIdof the agent authenticated to this session.Gets the rate of the service clock.getDate()Gets the service date which may be the current date or the effective date in which this session exists.Gets the effective agent in use by this session.Gets theIdof the effective agent in use by this session.Gets theDisplayTextformatTypepreference in effect for this session.Gets the locale indicating the localization preferences in effect for this session.booleanTests if an agent is authenticated to this session.Starts a new transaction for this sesson.booleanTests for the availability of transactions.
-
Method Details
-
canAssignTodoProducers
boolean canAssignTodoProducers()Tests if this user can alter todo producer/checklist mappings. A return of true does not guarantee successful authorization. A return of false indicates that it is known mapping methods in this session will result in aPERMISSION_DENIED. This is intended as a hint to an application that may opt not to offer lookup operations to unauthorized users.- Returns:
falseif mapping is not authorized,trueotherwise- Compliance:
mandatory- This method must be implemented.
-
canAssignTodoProducersToChecklist
Tests if this user can alter todo producer/checklist mappings. A return of true does not guarantee successful authorization. A return of false indicates that it is known mapping methods in this session will result in aPERMISSION_DENIED. This is intended as a hint to an application that may opt not to offer lookup operations to unauthorized users.- Parameters:
checklistId- theIdof theChecklist- Returns:
falseif mapping is not authorized,trueotherwise- Throws:
NullArgumentException-checklistIdisnull- Compliance:
mandatory- This method must be implemented.
-
getAssignableChecklistIds
Gets a list of checklists including and under the given checklist node in which any todo producer can be assigned.- Parameters:
checklistId- theIdof theChecklist- Returns:
- list of assignable checklist
Ids - Throws:
NullArgumentException-checklistIdisnullOperationFailedException- unable to complete request- Compliance:
mandatory- This method must be implemented.
-
getAssignableChecklistIdsForTodoProducer
IdList getAssignableChecklistIdsForTodoProducer(Id checklistId, Id todoProducerId) throws OperationFailedException Gets a list of checklists including and under the given checklist node in which a specific todo producer can be assigned.- Parameters:
checklistId- theIdof theChecklisttodoProducerId- theIdof theTodoProducer- Returns:
- list of assignable checklist
Ids - Throws:
NullArgumentException-checklistIdortodoProducerIdisnullOperationFailedException- unable to complete request- Compliance:
mandatory- This method must be implemented.
-
assignTodoProducerToChecklist
void assignTodoProducerToChecklist(Id todoProducerId, Id checklistId) throws AlreadyExistsException, NotFoundException, OperationFailedException, PermissionDeniedException Adds an existingTodoProducerto anChecklist.- Parameters:
todoProducerId- theIdof theTodoProducerchecklistId- theIdof theChecklist- Throws:
AlreadyExistsException-todoProducerIdis already assigned tochecklistIdNotFoundException-todoProducerIdorchecklistIdnot foundNullArgumentException-todoProducerIdorchecklistIdisnullOperationFailedException- unable to complete requestPermissionDeniedException- authorization failure- Compliance:
mandatory- This method must be implemented.
-
unassignTodoProducerFromChecklist
void unassignTodoProducerFromChecklist(Id todoProducerId, Id checklistId) throws NotFoundException, OperationFailedException, PermissionDeniedException Removes aTodoProducerfrom anChecklist.- Parameters:
todoProducerId- theIdof theTodoProducerchecklistId- theIdof theChecklist- Throws:
NotFoundException-todoProducerIdorchecklistIdnot found ortodoProducerIdis not assigned tochecklistIdNullArgumentException-todoProducerIdorchecklistIdisnullOperationFailedException- unable to complete requestPermissionDeniedException- authorization failure- Compliance:
mandatory- This method must be implemented.
-
reassignTodoProducerToChecklist
void reassignTodoProducerToChecklist(Id todoProducerId, Id fromChecklistId, Id toChecklistId) throws AlreadyExistsException, NotFoundException, OperationFailedException, PermissionDeniedException Moves aTodoProducerfrom oneChecklistto another. Mappings to otherChecklistsare unaffected.- Parameters:
todoProducerId- theIdof theTodoProducerfromChecklistId- theIdof the currentChecklisttoChecklistId- theIdof the destinationChecklist- Throws:
AlreadyExistsException-todoProducerIdalready assigned totoChecklistIdNotFoundException-todoProducerId, fromChecklistId, ortoChecklistIdnot found ortodoProducerId, not mapped tofromChecklistIdNullArgumentException-todoProducerId,, fromChecklistId, ortoChecklistIdisnullOperationFailedException- unable to complete requestPermissionDeniedException- authorization failure- Compliance:
mandatory- This method must be implemented.
-