Interface StepConstrainerAdminSession
- All Superinterfaces:
AutoCloseable, Closeable, OsidSession, OsidSession
This session creates and removes step constrainers. The data for create
and update is provided via the StepConstrainerForm .
-
Method Summary
Modifier and TypeMethodDescriptionvoidaliasStepConstrainer(Id stepConstrainerId, Id aliasId) Adds aIdto aStepConstrainerfor the purpose of creating compatibility.booleanTests if this user can create step constrainers.booleancanCreateStepConstrainerWithRecordTypes(Type[] stepConstrainerRecordTypes) Tests if this user can create a singleStepConstrainerusing the desired record types.booleanTests if this user can delete step constrainers.booleanTests if this user can manageIdaliases for step constrainers.booleanTests if this user can update step constrainers.createStepConstrainer(StepConstrainerForm stepConstrainerForm) Creates a newStepConstrainer.voiddeleteStepConstrainer(Id stepConstrainerId) Deletes aStepConstrainer.Gets theOfficeassociated with this session.Gets theOfficeIdassociated with this session.getStepConstrainerFormForCreate(Type[] stepConstrainerRecordTypes) Gets the step constrainer form for creating new step constrainers.getStepConstrainerFormForUpdate(Id stepConstrainerId) Gets the step constrainer form for updating an existing step constrainer.voidupdateStepConstrainer(StepConstrainerForm stepConstrainerForm) Updates an existing step constrainer.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
-
getOfficeId
Id getOfficeId()Gets theOfficeIdassociated with this session.- Returns:
- the
Office Idassociated with this session - Compliance:
mandatory- This method must be implemented.
-
getOffice
Gets theOfficeassociated with this session.- Returns:
- the office
- Throws:
OperationFailedException- unable to complete requestPermissionDeniedException- authorization failure- Compliance:
mandatory- This method must be implemented.
-
canCreateStepConstrainer
boolean canCreateStepConstrainer()Tests if this user can create step constrainers. A return of true does not guarantee successful authorization. A return of false indicates that it is known creating aStepConstrainerwill result in aPERMISSION_DENIED. This is intended as a hint to an application that may opt not to offer create operations to an unauthorized user.- Returns:
falseifStepConstrainercreation is not authorized,trueotherwise- Compliance:
mandatory- This method must be implemented.
-
canCreateStepConstrainerWithRecordTypes
Tests if this user can create a singleStepConstrainerusing the desired record types. WhileWorkflowRulesManager.getStepConstrainerRecordTypes()can be used to examine which records are supported, this method tests which record(s) are required for creating a specificStepConstrainer. Providing an empty array tests if aStepConstrainercan be created with no records.- Parameters:
stepConstrainerRecordTypes- array of step constrainer record types- Returns:
trueifStepConstrainercreation using the specified recordTypesis supported,falseotherwise- Throws:
NullArgumentException-stepConstrainerRecordTypesisnull- Compliance:
mandatory- This method must be implemented.
-
getStepConstrainerFormForCreate
StepConstrainerForm getStepConstrainerFormForCreate(Type[] stepConstrainerRecordTypes) throws OperationFailedException, PermissionDeniedException Gets the step constrainer form for creating new step constrainers. A new form should be requested for each create transaction.- Parameters:
stepConstrainerRecordTypes- array of step constrainer record types- Returns:
- the step constrainer form
- Throws:
NullArgumentException-stepConstrainerRecordTypesisnullOperationFailedException- unable to complete requestPermissionDeniedException- authorization failureUnsupportedException- unable to get form for requested record types- Compliance:
mandatory- This method must be implemented.
-
createStepConstrainer
StepConstrainer createStepConstrainer(StepConstrainerForm stepConstrainerForm) throws OperationFailedException, PermissionDeniedException Creates a newStepConstrainer.- Parameters:
stepConstrainerForm- the form for thisStepConstrainer- Returns:
- the new
StepConstrainer - Throws:
IllegalStateException-stepConstrainerFormalready used in a create transactionInvalidArgumentException- one or more of the form elements is invalidNullArgumentException-stepConstrainerFormisnullOperationFailedException- unable to complete requestPermissionDeniedException- authorization failureUnsupportedException-stepConstrainerFormdid not originate fromgetStepConstrainerFormForCreate()- Compliance:
mandatory- This method must be implemented.
-
canUpdateStepConstrainers
boolean canUpdateStepConstrainers()Tests if this user can update step constrainers. A return of true does not guarantee successful authorization. A return of false indicates that it is known updating aStepConstrainerwill result in aPERMISSION_DENIED. This is intended as a hint to an application that may opt not to offer update operations to an unauthorized user.- Returns:
falseifStepConstrainermodification is not authorized,trueotherwise- Compliance:
mandatory- This method must be implemented.
-
getStepConstrainerFormForUpdate
StepConstrainerForm getStepConstrainerFormForUpdate(Id stepConstrainerId) throws NotFoundException, OperationFailedException, PermissionDeniedException Gets the step constrainer form for updating an existing step constrainer. A new step constrainer form should be requested for each update transaction.- Parameters:
stepConstrainerId- theIdof theStepConstrainer- Returns:
- the step constrainer form
- Throws:
NotFoundException-stepConstrainerIdis not foundNullArgumentException-stepConstrainerIdisnullOperationFailedException- unable to complete requestPermissionDeniedException- authorization failure- Compliance:
mandatory- This method must be implemented.
-
updateStepConstrainer
void updateStepConstrainer(StepConstrainerForm stepConstrainerForm) throws OperationFailedException, PermissionDeniedException Updates an existing step constrainer.- Parameters:
stepConstrainerForm- the form containing the elements to be updated- Throws:
IllegalStateException-stepConstrainerFormalready used in an update transactionInvalidArgumentException- the form contains an invalid valueNullArgumentException-stepConstrainerFormisnullOperationFailedException- unable to complete requestPermissionDeniedException- authorization failureUnsupportedException-stepConstrainerFormdid not originate fromgetStepConstrainerFormForUpdate()- Compliance:
mandatory- This method must be implemented.
-
canDeleteStepConstrainers
boolean canDeleteStepConstrainers()Tests if this user can delete step constrainers. A return of true does not guarantee successful authorization. A return of false indicates that it is known deleting aStepConstrainerwill result in aPERMISSION_DENIED. This is intended as a hint to an application that may opt not to offer delete operations to an unauthorized user.- Returns:
falseifStepConstrainerdeletion is not authorized,trueotherwise- Compliance:
mandatory- This method must be implemented.
-
deleteStepConstrainer
void deleteStepConstrainer(Id stepConstrainerId) throws NotFoundException, OperationFailedException, PermissionDeniedException Deletes aStepConstrainer.- Parameters:
stepConstrainerId- theIdof theStepConstrainerto remove- Throws:
NotFoundException-stepConstrainerIdnot foundNullArgumentException-stepConstrainerIdisnullOperationFailedException- unable to complete requestPermissionDeniedException- authorization failure- Compliance:
mandatory- This method must be implemented.
-
canManageStepConstrainerAliases
boolean canManageStepConstrainerAliases()Tests if this user can manageIdaliases for step constrainers. A return of true does not guarantee successful authorization. A return of false indicates that it is known changing an alias will result in aPERMISSION_DENIED. This is intended as a hint to an application that may opt not to offer alias operations to an unauthorized user.- Returns:
falseifStepConstraineraliasing is not authorized,trueotherwise- Compliance:
mandatory- This method must be implemented.
-
aliasStepConstrainer
void aliasStepConstrainer(Id stepConstrainerId, Id aliasId) throws AlreadyExistsException, NotFoundException, OperationFailedException, PermissionDeniedException Adds aIdto aStepConstrainerfor the purpose of creating compatibility. The primaryIdof theStepConstraineris determined by the provider. The newIdperforms as an alias to the primaryId. If the alias is a pointer to another step constrainer. it is reassigned to the given step constrainerId.- Parameters:
stepConstrainerId- theIdof aStepConstraineraliasId- the aliasId- Throws:
AlreadyExistsException-aliasIdis already assignedNotFoundException-stepConstrainerIdnot foundNullArgumentException-stepConstrainerIdoraliasIdisnullOperationFailedException- unable to complete requestPermissionDeniedException- authorization failure- Compliance:
mandatory- This method must be implemented.
-