Interface EntryForm

All Superinterfaces:
Extensible, Identifiable, OsidBrowsableForm, OsidExtensibleForm, OsidForm, OsidIdentifiableForm, OsidObjectForm, OsidSubjugateableForm, Suppliable
All Known Subinterfaces:
EntryBatchForm

public interface EntryForm extends OsidObjectForm, OsidSubjugateableForm

This is the form for creating and updating Entries. Like all OsidForms, various data elements may be set here for use in the create and update methods in the EntryAdminSession. For each data element that may be set, metadata may be examined to provide display hints or data constraints.

  • Method Details

    • getModelMetadata

      Metadata getModelMetadata()
      Gets the metadata for a model.
      Returns:
      metadata for the model
      Compliance:
      mandatory - This method must be implemented.
    • setModel

      void setModel(Id modelId)
      Sets the model.
      Parameters:
      modelId - the new model
      Throws:
      InvalidArgumentException - modelId is invalid
      NoAccessException - Metadata.isReadOnly() is true
      NullArgumentException - modelId is null
      Compliance:
      mandatory - This method must be implemented.
    • clearModel

      void clearModel()
      Removes the model.
      Throws:
      NoAccessException - Metadata.isRequired() is true or Metadata.isReadOnly() is true
      Compliance:
      mandatory - This method must be implemented.
    • getItemMetadata

      Metadata getItemMetadata()
      Gets the metadata for an item.
      Returns:
      metadata for the item
      Compliance:
      mandatory - This method must be implemented.
    • setItem

      void setItem(Id itemId)
      Sets the item.
      Parameters:
      itemId - the new item
      Throws:
      InvalidArgumentException - itemId is invalid
      NoAccessException - Metadata.isReadOnly() is true
      NullArgumentException - itemId is null
      Compliance:
      mandatory - This method must be implemented.
    • clearItem

      void clearItem()
      Removes the item.
      Throws:
      NoAccessException - Metadata.isRequired() is true or Metadata.isReadOnly() is true
      Compliance:
      mandatory - This method must be implemented.
    • getQuantityMetadata

      Metadata getQuantityMetadata()
      Gets the metadata for the quantity.
      Returns:
      metadata for the quantity
      Compliance:
      mandatory - This method must be implemented.
    • setQuantity

      void setQuantity(BigDecimal quantity)
      Sets the quantity.
      Parameters:
      quantity - the new quantity
      Throws:
      InvalidArgumentException - quantity is invalid
      NoAccessException - Metadata.isReadOnly() is true
      Compliance:
      mandatory - This method must be implemented.
    • clearQuantity

      void clearQuantity()
      Removes the quantity.
      Throws:
      NoAccessException - Metadata.isRequired() is true or Metadata.isReadOnly() is true
      Compliance:
      mandatory - This method must be implemented.
    • getUnitTypeMetadata

      Metadata getUnitTypeMetadata()
      Gets the metadata for the unit type.
      Returns:
      metadata for the unit type
      Compliance:
      mandatory - This method must be implemented.
    • setUnitType

      void setUnitType(Type type)
      Sets the unit type.
      Parameters:
      type - the new unit type
      Throws:
      InvalidArgumentException - type is invalid
      NoAccessException - Metadata.isReadOnly() is true
      NullArgumentException - type is null
      Compliance:
      mandatory - This method must be implemented.
    • clearUnitType

      void clearUnitType()
      Removes the unit type.
      Throws:
      NoAccessException - Metadata.isRequired() is true or Metadata.isReadOnly() is true
      Compliance:
      mandatory - This method must be implemented.
    • getEntryFormRecord

      EntryFormRecord getEntryFormRecord(Type entryRecordType) throws OperationFailedException
      Gets the EntryFormRecord corresponding to the given entry record Type.
      Parameters:
      entryRecordType - an entry record type
      Returns:
      the entry form record
      Throws:
      NullArgumentException - entryRecordType is null
      OperationFailedException - unable to complete request
      UnsupportedException - hasRecordType(entryRecordType) is false
      Compliance:
      mandatory - This method must be implemented.