Interface OfferingConstrainerRuleApplicationSession
- All Superinterfaces:
AutoCloseable, Closeable, OsidSession, OsidSession
This session provides methods to apply OfferingConstrainers to
CanonicalUnits to constrain the offerings for a canonical unit. A
CanonicalUnit with multiple OfferingConstrainers means any
positive rule evaluation across the result in an effective
CanonicalUnit .
-
Method Summary
Modifier and TypeMethodDescriptionvoidassignOfferingConstrainerToCanonicalUnit(Id offeringConstrainerId, Id canonicalUnitId) Adds an existingOfferingConstrainerto aCanonicalUnit.booleanTests if this user can alter offering constrainer/canonical unit mappings.booleanTests if this user can orderOfferingConstrainers.Gets theCatalogueassociated with this session.Gets theCatalogueIdassociated with this session.voidmoveOfferingConstrainerAhead(Id offeringConstrainerId, Id canonicalUnitId, Id referenceId) Reorders offering constrainers for a canonical unit by moving the specified offering constrainer in front of a reference offering constrainer.voidmoveOfferingConstrainerBehind(Id offeringConstrainerId, Id canonicalUnitId, Id referenceId) Reorders offering constrainers for a canonical unit by moving the specified offering constrainer behind a reference offering constrainer.voidorderOfferingConstrainers(Id[] offeringConstrainerIds, Id canonicalUnitId) Reorders a set of offering constrainers for a canonical unit.voidunassignOfferingConstrainerFromCanonicalUnit(Id offeringConstrainerId, Id canonicalUnitId) Removes anOfferingConstrainerfrom aCanonicalUnit.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
-
getCatalogueId
Id getCatalogueId()Gets theCatalogueIdassociated with this session.- Returns:
- the
Catalogue Idassociated with this session - Compliance:
mandatory- This method must be implemented.
-
getCatalogue
Gets theCatalogueassociated with this session.- Returns:
- the catalogue
- Throws:
OperationFailedException- unable to complete requestPermissionDeniedException- authorization failure- Compliance:
mandatory- This method must be implemented.
-
canAssignOfferingConstrainers
boolean canAssignOfferingConstrainers()Tests if this user can alter offering constrainer/canonical unit 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.
-
assignOfferingConstrainerToCanonicalUnit
void assignOfferingConstrainerToCanonicalUnit(Id offeringConstrainerId, Id canonicalUnitId) throws AlreadyExistsException, NotFoundException, OperationFailedException, PermissionDeniedException Adds an existingOfferingConstrainerto aCanonicalUnit.- Parameters:
offeringConstrainerId- theIdof theOfferingConstrainercanonicalUnitId- theIdof theCanonicalUnit- Throws:
AlreadyExistsException-offeringConstrainerIdalready applied tocanonicalUnitIdNotFoundException-offeringConstrainerIdorcanonicalUnitIdnot foundNullArgumentException-offeringConstrainerIdorcanonicalUnitIdisnullOperationFailedException- unable to complete requestPermissionDeniedException- authorization failure- Compliance:
mandatory- This method must be implemented.
-
unassignOfferingConstrainerFromCanonicalUnit
void unassignOfferingConstrainerFromCanonicalUnit(Id offeringConstrainerId, Id canonicalUnitId) throws NotFoundException, OperationFailedException, PermissionDeniedException Removes anOfferingConstrainerfrom aCanonicalUnit.- Parameters:
offeringConstrainerId- theIdof theOfferingConstrainercanonicalUnitId- theIdof theCanonicalUnit- Throws:
NotFoundException-offeringConstrainerIdorcanonicalUnitIdnot found orofferingConstrainerIdalready applied tocanonicalUnitIdNullArgumentException-offeringConstrainerIdorcanonicalUnitIdisnullOperationFailedException- unable to complete requestPermissionDeniedException- authorization failure- Compliance:
mandatory- This method must be implemented.
-
canSequenceOfferingConstrainers
boolean canSequenceOfferingConstrainers()Tests if this user can orderOfferingConstrainers. A return of true does not guarantee successful authorization. A return of false indicates that it is known sequencing operations will result in aPERMISSION_DENIED. This is intended as a hint to an application that may opt not to offer sequencing operations to an unauthorized user.- Returns:
falseifOfferingConstrainerordering is not authorized,trueotherwise- Compliance:
mandatory- This method must be implemented.
-
moveOfferingConstrainerAhead
void moveOfferingConstrainerAhead(Id offeringConstrainerId, Id canonicalUnitId, Id referenceId) throws NotFoundException, OperationFailedException, PermissionDeniedException Reorders offering constrainers for a canonical unit by moving the specified offering constrainer in front of a reference offering constrainer.- Parameters:
offeringConstrainerId- theIdof anOfferingConstrainercanonicalUnitId- theIdof aCanonicalUnitreferenceId- the reference offering constrainerId- Throws:
NotFoundException-offeringConstrainerId, canonicalUnitId, orreferenceIdnot found or,offeringConstrainerIdorreferenceIdnot related tocanonicalUnitIdNullArgumentException-offeringConstrainerId, canonicalUnitId, orreferenceIdisnullOperationFailedException- unable to complete requestPermissionDeniedException- authorization failure- Compliance:
mandatory- This method must be implemented.
-
moveOfferingConstrainerBehind
void moveOfferingConstrainerBehind(Id offeringConstrainerId, Id canonicalUnitId, Id referenceId) throws NotFoundException, OperationFailedException, PermissionDeniedException Reorders offering constrainers for a canonical unit by moving the specified offering constrainer behind a reference offering constrainer.- Parameters:
offeringConstrainerId- theIdof anOfferingConstrainercanonicalUnitId- theIdof aCanonicalUnitreferenceId- the reference offering constrainerId- Throws:
NotFoundException-offeringConstrainerId, canonicalUnitId, orreferenceIdnot found or,offeringConstrainerIdorreferenceIdnot related tocanonicalUnitIdNullArgumentException-offeringConstrainerId, canonicalUnitId, orreferenceIdisnullOperationFailedException- unable to complete requestPermissionDeniedException- authorization failure- Compliance:
mandatory- This method must be implemented.
-
orderOfferingConstrainers
void orderOfferingConstrainers(Id[] offeringConstrainerIds, Id canonicalUnitId) throws NotFoundException, OperationFailedException, PermissionDeniedException Reorders a set of offering constrainers for a canonical unit.- Parameters:
offeringConstrainerIds- theIdsfor a set ofOfferingConstrainerscanonicalUnitId- theIdof aCanonicalUnit- Throws:
NotFoundException-canonicalUnitIdnot found or, anofferingConstrainerIdnot related tocanonicalUnitIdNullArgumentException-offeringConstrainerIdsorcanonicalUnitIdisnullOperationFailedException- unable to complete requestPermissionDeniedException- authorization failure- Compliance:
mandatory- This method must be implemented.
-