public interface ProjectCampusAssignmentSession extends OsidSession
This session provides methods to re-assign Projects to
Campuses. A Project may map to multiple
Campuses and removing the last reference to a
Project is the equivalent of deleting it. Each Campus
may have its own authorizations governing who is allowed to
operate on it.
Adding a reference of a Project to another
Campus is not a copy operation (eg: does not change its Id
).
| Modifier and Type | Method and Description |
|---|---|
void |
assignProjectToCampus(Id projectId,
Id campusId)
Adds an existing
Project to a Campus. |
boolean |
canAssignProjects()
Tests if this user can alter project/campus mappings.
|
boolean |
canAssignProjectsToCampus(Id campusId)
Tests if this user can alter project/campus mappings.
|
IdList |
getAssignableCampusIds(Id campusId)
Gets a list of campuses including and under the given campus node in
which any project can be assigned.
|
IdList |
getAssignableCampusIdsForProject(Id campusId,
Id projectId)
Gets a list of campuses including and under the given campus node in
which a specific project can be assigned.
|
void |
unassignProjectFromCampus(Id projectId,
Id campusId)
Removes a
Project from a Campus. |
getAuthenticatedAgent, getAuthenticatedAgentId, getClockRate, getDate, getEffectiveAgent, getEffectiveAgentId, getFormatType, getLocale, isAuthenticated, startTransaction, supportsTransactionscloseboolean canAssignProjects()
PERMISSION_DENIED. This is intended as a hint to
an application that may opt not to offer assignment operations to
unauthorized users. false if mapping is not authorized, true
otherwisemandatory - This method must be implemented. boolean canAssignProjectsToCampus(Id campusId)
PERMISSION_DENIED. This is intended as a hint to
an application that may opt not to offer assignment operations to
unauthorized users.campusId - the Id of the Campus false if mapping is not authorized, true
otherwiseNullArgumentException - campusId is
null mandatory - This method must be implemented. IdList getAssignableCampusIds(Id campusId) throws OperationFailedException
campusId - the Id of the Campus Ids NullArgumentException - campusId is
null OperationFailedException - unable to complete requestmandatory - This method must be implemented. IdList getAssignableCampusIdsForProject(Id campusId, Id projectId) throws OperationFailedException
campusId - the Id of the Campus projectId - the Id of the Project Ids NullArgumentException - campusId or
projectId is null OperationFailedException - unable to complete requestmandatory - This method must be implemented. void assignProjectToCampus(Id projectId, Id campusId) throws AlreadyExistsException, NotFoundException, OperationFailedException, PermissionDeniedException
Project to a Campus. projectId - the Id of the Project campusId - the Id of the Campus AlreadyExistsException - projectId is
already assigned to campusId NotFoundException - projectId or
campusId not foundNullArgumentException - projectId or
campusId is null OperationFailedException - unable to complete requestPermissionDeniedException - authorization failuremandatory - This method must be implemented. void unassignProjectFromCampus(Id projectId, Id campusId) throws NotFoundException, OperationFailedException, PermissionDeniedException
Project from a Campus. projectId - the Id of the Project campusId - the Id of the Campus NotFoundException - projectId or
campusId not found or projectId not
assigned to campusId NullArgumentException - projectId or
campusId is null OperationFailedException - unable to complete requestPermissionDeniedException - authorization failuremandatory - This method must be implemented.