Interface Item
- All Superinterfaces:
Aggregateable, Browsable, Extensible, Identifiable, OsidObject
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 Summary
Modifier and TypeMethodDescriptionGets theIdsof the answers.Gets the answers.getItemRecord(Type itemRecordType) Gets the item record corresponding to the givenItemrecordType.Gets theIdsof anyObjectivescorresponding to this item.Gets the anyObjectivescorresponding to this item.Gets the question.Gets theIdof theQuestion.Methods inherited from interface Browsable
getProperties, getPropertiesByRecordTypeModifier and TypeMethodDescriptionGets a list of properties.getPropertiesByRecordType(Type recordType) Gets a list of properties corresponding to the specified record type.Methods inherited from interface Extensible
getRecordTypes, hasRecordTypeModifier and TypeMethodDescriptionGets the record types available in this object.booleanhasRecordType(Type recordType) Tests if this object supports the given recordType.Methods inherited from interface Identifiable
getId, isCurrentMethods inherited from interface OsidObject
getDescription, getDisplayName, getGenusType, isOfGenusTypeModifier and TypeMethodDescriptionGets the description associated with this instance of this OSID object.Gets the preferred display name associated with this instance of this OSID object appropriate for display to the user.Gets the genus type of this object.booleanisOfGenusType(Type genusType) Tests if this object is of the given genusType.
-
Method Details
-
getLearningObjectiveIds
IdList getLearningObjectiveIds()Gets theIdsof anyObjectivescorresponding to this item.- Returns:
- the learning objective
Ids - Compliance:
mandatory- This method must be implemented.
-
getLearningObjectives
Gets the anyObjectivescorresponding to this item.- Returns:
- the learning objectives
- Throws:
OperationFailedException- unable to complete request- Compliance:
mandatory- This method must be implemented.
-
getQuestionId
Id getQuestionId()Gets theIdof theQuestion.- Returns:
- the question
Id - Compliance:
mandatory- This method must be implemented.
-
getQuestion
Gets the question.- Returns:
- the question
- Throws:
OperationFailedException- unable to complete request- Compliance:
mandatory- This method must be implemented.
-
getAnswerIds
IdList getAnswerIds()Gets theIdsof 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
Gets the item record corresponding to the givenItemrecordType. This method is used to retrieve an object implementing the requested records. TheitemRecordTypemay be theTypereturned ingetRecordTypes()or any of its parents in aTypehierarchy wherehasRecordType(itemRecordType)istrue.- Parameters:
itemRecordType- the type of the record to retrieve- Returns:
- the item record
- Throws:
NullArgumentException-itemRecordTypeisnullOperationFailedException- unable to complete requestUnsupportedException-hasRecordType(itemRecordType)isfalse- Compliance:
mandatory- This method must be implemented.
-