Interface OfferingConstrainerEnablerAdminSession

All Superinterfaces:
AutoCloseable, Closeable, OsidSession, OsidSession

public interface OfferingConstrainerEnablerAdminSession extends OsidSession

This session creates and removes offering constrainer enablers. The data for create and update is provided via the OfferingConstrainerEnablerForm .

  • Method Details

    • getCatalogueId

      Id getCatalogueId()
      Gets the Catalogue Id associated with this session.
      Returns:
      the Catalogue Id associated with this session
      Compliance:
      mandatory - This method must be implemented.
    • getCatalogue

      Gets the Catalogue associated with this session.
      Returns:
      the catalogue
      Throws:
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • canCreateOfferingConstrainerEnabler

      boolean canCreateOfferingConstrainerEnabler()
      Tests if this user can create offering constrainer enablers. A return of true does not guarantee successful authorization. A return of false indicates that it is known creating an OfferingConstrainerEnabler will result in a PERMISSION_DENIED . This is intended as a hint to an application that may opt not to offer create operations to an unauthorized user.
      Returns:
      false if OfferingConstrainerEnabler creation is not authorized, true otherwise
      Compliance:
      mandatory - This method must be implemented.
    • canCreateOfferingConstrainerEnablerWithRecordTypes

      boolean canCreateOfferingConstrainerEnablerWithRecordTypes(Type[] offeringConstrainerEnablerRecordTypes)
      Tests if this user can create a single OfferingConstrainerEnabler using the desired record types. While OfferingRulesManager.getOfferingConstrainerEnablerRecordTypes() can be used to examine which records are supported, this method tests which record(s) are required for creating a specific OfferingConstrainerEnabler . Providing an empty array tests if an OfferingConstrainerEnabler can be created with no records.
      Parameters:
      offeringConstrainerEnablerRecordTypes - array of offering constrainer enabler record types
      Returns:
      true if OfferingConstrainerEnabler creation using the specified record Types is supported, false otherwise
      Throws:
      NullArgumentException - offeringConstrainerEnablerRecordTypes is null
      Compliance:
      mandatory - This method must be implemented.
    • getOfferingConstrainerEnablerFormForCreate

      OfferingConstrainerEnablerForm getOfferingConstrainerEnablerFormForCreate(Type[] offeringConstrainerEnablerRecordTypes) throws OperationFailedException, PermissionDeniedException
      Gets the offering constrainer enabler form for creating new offering constrainer enablers. A new form should be requested for each create transaction.
      Parameters:
      offeringConstrainerEnablerRecordTypes - array of offering constrainer enabler record types
      Returns:
      the offering constrainer enabler form
      Throws:
      NullArgumentException - offeringConstrainerEnablerRecordTypes is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      UnsupportedException - unable to get form for requested record types
      Compliance:
      mandatory - This method must be implemented.
    • createOfferingConstrainerEnabler

      OfferingConstrainerEnabler createOfferingConstrainerEnabler(OfferingConstrainerEnablerForm offeringConstrainerEnablerForm) throws OperationFailedException, PermissionDeniedException
      Creates a new OfferingConstrainerEnabler .
      Parameters:
      offeringConstrainerEnablerForm - the form for this OfferingConstrainerEnabler
      Returns:
      the new OfferingConstrainerEnabler
      Throws:
      IllegalStateException - offeringConstrainerEnablerForm already used in a create transaction
      InvalidArgumentException - one or more of the form elements is invalid
      NullArgumentException - offeringConstrainerEnablerForm is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      UnsupportedException - offeringConstrainerEnablerForm did not originate from getOfferingConstrainerEnablerFormForCreate()
      Compliance:
      mandatory - This method must be implemented.
    • canUpdateOfferingConstrainerEnablers

      boolean canUpdateOfferingConstrainerEnablers()
      Tests if this user can update offering constrainer enablers. A return of true does not guarantee successful authorization. A return of false indicates that it is known updating an OfferingConstrainerEnabler will result in a PERMISSION_DENIED . This is intended as a hint to an application that may opt not to offer update operations to an unauthorized user.
      Returns:
      false if OfferingConstrainerEnabler modification is not authorized, true otherwise
      Compliance:
      mandatory - This method must be implemented.
    • getOfferingConstrainerEnablerFormForUpdate

      OfferingConstrainerEnablerForm getOfferingConstrainerEnablerFormForUpdate(Id offeringConstrainerEnablerId) throws NotFoundException, OperationFailedException, PermissionDeniedException
      Gets the offering constrainer enabler form for updating an existing offering constrainer enabler. A new offering constrainer enabler form should be requested for each update transaction.
      Parameters:
      offeringConstrainerEnablerId - the Id of the OfferingConstrainerEnabler
      Returns:
      the offering constrainer enabler form
      Throws:
      NotFoundException - offeringConstrainerEnablerId is not found
      NullArgumentException - offeringConstrainerEnablerId is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • updateOfferingConstrainerEnabler

      void updateOfferingConstrainerEnabler(OfferingConstrainerEnablerForm offeringConstrainerEnablerForm) throws OperationFailedException, PermissionDeniedException
      Updates an existing offering constrainer enabler.
      Parameters:
      offeringConstrainerEnablerForm - the form containing the elements to be updated
      Throws:
      IllegalStateException - offeringConstrainerEnablerForm already used in an update transaction
      InvalidArgumentException - the form contains an invalid value
      NullArgumentException - offeringConstrainerEnablerForm is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      UnsupportedException - offeringConstrainerEnablerForm did not originate from getOfferingConstrainerEnablerFormForUpdate()
      Compliance:
      mandatory - This method must be implemented.
    • canDeleteOfferingConstrainerEnablers

      boolean canDeleteOfferingConstrainerEnablers()
      Tests if this user can delete offering constrainer enablers. A return of true does not guarantee successful authorization. A return of false indicates that it is known deleting an OfferingConstrainerEnabler will result in a PERMISSION_DENIED . This is intended as a hint to an application that may opt not to offer delete operations to an unauthorized user.
      Returns:
      false if OfferingConstrainerEnabler deletion is not authorized, true otherwise
      Compliance:
      mandatory - This method must be implemented.
    • deleteOfferingConstrainerEnabler

      void deleteOfferingConstrainerEnabler(Id offeringConstrainerEnablerId) throws NotFoundException, OperationFailedException, PermissionDeniedException
      Deletes an OfferingConstrainerEnabler .
      Parameters:
      offeringConstrainerEnablerId - the Id of the OfferingConstrainerEnabler to remove
      Throws:
      NotFoundException - offeringConstrainerEnablerId not found
      NullArgumentException - offeringConstrainerEnablerId is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • canManageOfferingConstrainerEnablerAliases

      boolean canManageOfferingConstrainerEnablerAliases()
      Tests if this user can manage Id aliases for offering constrainer enablers. A return of true does not guarantee successful authorization. A return of false indicates that it is known changing an alias will result in a PERMISSION_DENIED . This is intended as a hint to an application that may opt not to offer alias operations to an unauthorized user.
      Returns:
      false if OfferingConstrainerEnabler aliasing is not authorized, true otherwise
      Compliance:
      mandatory - This method must be implemented.
    • aliasOfferingConstrainerEnabler

      void aliasOfferingConstrainerEnabler(Id offeringConstrainerEnablerId, Id aliasId) throws AlreadyExistsException, NotFoundException, OperationFailedException, PermissionDeniedException
      Adds an Id to an OfferingConstrainerEnabler for the purpose of creating compatibility. The primary Id of the OfferingConstrainerEnabler is determined by the provider. The new Id performs as an alias to the primary Id . If the alias is a pointer to another offering constrainer enabler. it is reassigned to the given offering constrainer enabler Id .
      Parameters:
      offeringConstrainerEnablerId - the Id of an OfferingConstrainerEnabler
      aliasId - the alias Id
      Throws:
      AlreadyExistsException - aliasId is already assigned
      NotFoundException - offeringConstrainerEnablerId not found
      NullArgumentException - offeringConstrainerEnablerId or aliasId is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.