Interface Item

All Superinterfaces:
Aggregateable, Browsable, Extensible, Identifiable, OsidObject

public interface Item extends OsidObject, Aggregateable

An Item represents an individual assessment item such as a question. Like all OSID objects, a Item is identified by its Id and any persisted references should use the Id.

An Item is composed of a Question and an Answer.

  • Method Details

    • getLearningObjectiveIds

      IdList getLearningObjectiveIds()
      Gets the Ids of any Objectives corresponding to this item.
      Returns:
      the learning objective Ids
      Compliance:
      mandatory - This method must be implemented.
    • getLearningObjectives

      ObjectiveList getLearningObjectives() throws OperationFailedException
      Gets the any Objectives corresponding to this item.
      Returns:
      the learning objectives
      Throws:
      OperationFailedException - unable to complete request
      Compliance:
      mandatory - This method must be implemented.
    • getQuestionId

      Id getQuestionId()
      Gets the Id of the Question.
      Returns:
      the question Id
      Compliance:
      mandatory - This method must be implemented.
    • getQuestion

      Question getQuestion() throws OperationFailedException
      Gets the question.
      Returns:
      the question
      Throws:
      OperationFailedException - unable to complete request
      Compliance:
      mandatory - This method must be implemented.
    • getAnswerIds

      IdList getAnswerIds()
      Gets the Ids of the answers. Questions may have more than one acceptable answer.
      Returns:
      the answer Ids
      Compliance:
      mandatory - This method must be implemented.
    • getAnswers

      Gets the answers.
      Returns:
      the answers
      Throws:
      OperationFailedException - unable to complete request
      Compliance:
      mandatory - This method must be implemented.
    • getItemRecord

      ItemRecord getItemRecord(Type itemRecordType) throws OperationFailedException
      Gets the item record corresponding to the given Item record Type. This method is used to retrieve an object implementing the requested records. The itemRecordType may be the Type returned in getRecordTypes() or any of its parents in a Type hierarchy where hasRecordType(itemRecordType) is true.
      Parameters:
      itemRecordType - the type of the record to retrieve
      Returns:
      the item record
      Throws:
      NullArgumentException - itemRecordType is null
      OperationFailedException - unable to complete request
      UnsupportedException - hasRecordType(itemRecordType) is false
      Compliance:
      mandatory - This method must be implemented.