Interface DocetLookupSession
- All Superinterfaces:
AutoCloseable, Closeable, OsidSession, OsidSession
This session provides methods for retrieving Docets . The
Docet represents a collection of syllabi.
This session defines views that offer differing behaviors when retrieving multiple objects.
- comparative view: elements may be silently omitted or re-ordered
- plenary view: provides a complete view or is an error condition
- isolated course catalog view: All docet methods in this session
operate, retrieve and pertain to docetsdefined explicitly in the
current course catalog. Using an isolated view is useful for managing
docetswith the
DocetAdminSession. - federated course catalog view: All docet lookup methods in this session operate, retrieve and pertain to all docetsdefined in this course catalog and any other course catalogs implicitly available in this course catalog through course catalog inheritence.
- effective docet view: All docet lookup methods return docets where the current date falls in between the effective dates inclusive.
- any effective docet view: Docets of any effective date are returned from methods.
-
Method Summary
Modifier and TypeMethodDescriptionbooleanTests if this user can performDocetlookups.Gets theCourseCatalogassociated with this session.Gets theCourseCatalogIdassociated with this session.Gets theDocetspecified by itsId.Gets allDocets.getDocetsByGenusType(Type docetGenusType) Gets aDocetListcorresponding to the given docet genusTypewhich does not include docetsof genus types derived from the specifiedType.getDocetsByIds(IdList docetIds) Gets aDocetListcorresponding to the givenIdList.getDocetsByParentGenusType(Type docetGenusType) Gets aDocetListcorresponding to the given docet genusTypeand include any additional docetswith genus types derived from the specifiedType.getDocetsByRecordType(Type docetRecordType) Gets aDocetListcontaining the given docet recordType.getDocetsForActivityUnit(Id activityUnitId) Gets aDocetListfor the given activity unitId.getDocetsForActivityUnitOnDate(Id activityUnitId, DateTime from, DateTime to) Gets aDocetListfor an activity unit effective sduring the entire given date range inclusive but not confined to the date range.getDocetsForModule(Id moduleId) Gets aDocetListfor the given moduleId.getDocetsForModuleAndActivityUnit(Id moduleId, Id activityUnitId) Gets aDocetListfor the given module and activity unit.getDocetsForModuleAndActivityUnitOnDate(Id moduleId, Id activityUnitId, DateTime from, DateTime to) Gets aDocetListfor a module and activity unit effective during the entire given date range inclusive but not confined to the date range.getDocetsForModuleOnDate(Id moduleId, DateTime from, DateTime to) Gets aDocetListfor a module effective during the entire given date range inclusive but not confined to the date range.getDocetsOnDate(DateTime from, DateTime to) Gets aDocetListeffective sduring the entire given date range inclusive but not confined to the date range.voidAll docets of any effective dates are returned by all methods in this session.voidThe returns from the lookup methods may omit or translate elements based on this session, such as authorization, and not result in an error.voidOnly docets whose effective dates are current are returned by methods in this session.voidFederates the view for methods in this session.voidIsolates the view for methods in this session.voidA complete view of theDocetreturns is desired.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
-
getCourseCatalogId
Id getCourseCatalogId()Gets theCourseCatalogIdassociated with this session.- Returns:
- the
CourseCatalog Idassociated with this session - Compliance:
mandatory- This method must be implemented.
-
getCourseCatalog
Gets theCourseCatalogassociated with this session.- Returns:
- the course catalog
- Throws:
OperationFailedException- unable to complete requestPermissionDeniedException- authorization failure- Compliance:
mandatory- This method must be implemented.
-
canLookupDocets
boolean canLookupDocets()Tests if this user can performDocetlookups. A return of true does not guarantee successful authorization. A return of false indicates that it is known all methods in this session will result in aPERMISSION_DENIED. This is intended as a hint to an application that may not offer lookup operations to unauthorized users.- Returns:
falseif lookup methods are not authorized,trueotherwise- Compliance:
mandatory- This method must be implemented.
-
useComparativeDocetView
void useComparativeDocetView()The returns from the lookup methods may omit or translate elements based on this session, such as authorization, and not result in an error. This view is used when greater interoperability is desired at the expense of precision.- Compliance:
mandatory- This method is must be implemented.
-
usePlenaryDocetView
void usePlenaryDocetView()A complete view of theDocetreturns is desired. Methods will return what is requested or result in an error. This view is used when greater precision is desired at the expense of interoperability.- Compliance:
mandatory- This method is must be implemented.
-
useFederatedCourseCatalogView
void useFederatedCourseCatalogView()Federates the view for methods in this session. A federated view will include docetsin course catalogs which are children of this course catalog in the course catalog hierarchy.- Compliance:
mandatory- This method is must be implemented.
-
useIsolatedCourseCatalogView
void useIsolatedCourseCatalogView()Isolates the view for methods in this session. An isolated view restricts retrievals to this course catalog only.- Compliance:
mandatory- This method is must be implemented.
-
useEffectiveDocetView
void useEffectiveDocetView()Only docets whose effective dates are current are returned by methods in this session.- Compliance:
mandatory- This method is must be implemented.
-
useAnyEffectiveDocetView
void useAnyEffectiveDocetView()All docets of any effective dates are returned by all methods in this session.- Compliance:
mandatory- This method is must be implemented.
-
getDocet
Docet getDocet(Id docetId) throws NotFoundException, OperationFailedException, PermissionDeniedException Gets theDocetspecified by itsId. In plenary mode, the exactIdis found or aNOT_FOUNDresults. Otherwise, the returnedDocetmay have a differentIdthan requested, such as the case where a duplicateIdwas assigned to aDocetand retained for compatibility. In effective mode, docets are returned that are currently effective. In any effective mode, effective docets and those currently expired are returned.- Parameters:
docetId-Idof theDocet- Returns:
- the docet
- Throws:
NotFoundException-docetIdnot foundNullArgumentException-docetIdisnullOperationFailedException- unable to complete requestPermissionDeniedException- authorization failure- Compliance:
mandatory- This method is must be implemented.
-
getDocetsByIds
DocetList getDocetsByIds(IdList docetIds) throws NotFoundException, OperationFailedException, PermissionDeniedException Gets aDocetListcorresponding to the givenIdList. In plenary mode, the returned list contains all of the docetsspecified in theIdlist, in the order of the list, including duplicates, or an error results if anIdin the supplied list is not found or inaccessible. Otherwise, inaccessibleDocetsmay be omitted from the list and may present the elements in any order including returning a unique set. In effective mode, docets are returned that are currently effective. In any effective mode, effective docets and those currently expired are returned.- Parameters:
docetIds- the list ofIdsto retrieve- Returns:
- the returned
Docetlist - Throws:
NotFoundException- anId wasnot foundNullArgumentException-docetIdsisnullOperationFailedException- unable to complete requestPermissionDeniedException- authorization failure- Compliance:
mandatory- This method must be implemented.
-
getDocetsByGenusType
DocetList getDocetsByGenusType(Type docetGenusType) throws OperationFailedException, PermissionDeniedException Gets aDocetListcorresponding to the given docet genusTypewhich does not include docetsof genus types derived from the specifiedType. In plenary mode, the returned list contains all known docetsor an error results. Otherwise, the returned list may contain only those docets that are accessible through this session. In effective mode, docets are returned that are currently effective. In any effective mode, effective docets and those currently expired are returned.- Parameters:
docetGenusType- a docet genus type- Returns:
- the returned
Docetlist - Throws:
NullArgumentException-docetGenusTypeisnullOperationFailedException- unable to complete requestPermissionDeniedException- authorization failure- Compliance:
mandatory- This method must be implemented.
-
getDocetsByParentGenusType
DocetList getDocetsByParentGenusType(Type docetGenusType) throws OperationFailedException, PermissionDeniedException Gets aDocetListcorresponding to the given docet genusTypeand include any additional docetswith genus types derived from the specifiedType. In plenary mode, the returned list contains all known docetsor an error results. Otherwise, the returned list may contain only those docets that are accessible through this session. In effective mode, docets are returned that are currently effective. In any effective mode, effective docets and those currently expired are returned.- Parameters:
docetGenusType- a docet genus type- Returns:
- the returned
Docetlist - Throws:
NullArgumentException-docetGenusTypeisnullOperationFailedException- unable to complete requestPermissionDeniedException- authorization failure- Compliance:
mandatory- This method must be implemented.
-
getDocetsByRecordType
DocetList getDocetsByRecordType(Type docetRecordType) throws OperationFailedException, PermissionDeniedException Gets aDocetListcontaining the given docet recordType. In plenary mode, the returned list contains all known docetsor an error results. Otherwise, the returned list may contain only those docets that are accessible through this session. In effective mode, docets are returned that are currently effective. In any effective mode, effective docets and those currently expired are returned.- Parameters:
docetRecordType- a docet record type- Returns:
- the returned
Docetlist - Throws:
NullArgumentException-docetRecordTypeisnullOperationFailedException- unable to complete requestPermissionDeniedException- authorization failure- Compliance:
mandatory- This method must be implemented.
-
getDocetsOnDate
DocetList getDocetsOnDate(DateTime from, DateTime to) throws OperationFailedException, PermissionDeniedException Gets aDocetListeffective sduring the entire given date range inclusive but not confined to the date range. In plenary mode, the returned list contains all known docetsor an error results. Otherwise, the returned list may contain only those docets that are accessible through this session. In effective mode, docets are returned that are currently effective. In any effective mode, effective docets and those currently expired are returned.- Parameters:
from- s atsrting dateto- an ending date- Returns:
- the returned
Docetlist - Throws:
InvalidArgumentException-fromis greater thantoNullArgumentException-fromortoisnullOperationFailedException- unable to complete requestPermissionDeniedException- authorization failure- Compliance:
mandatory- This method must be implemented.
-
getDocetsForModule
DocetList getDocetsForModule(Id moduleId) throws OperationFailedException, PermissionDeniedException Gets aDocetListfor the given moduleId. In plenary mode, the returned list contains all known docetsor an error results. Otherwise, the returned list may contain only those docets that are accessible through this session. In effective mode, docets are returned that are currently effective. In any effective mode, effective docets and those currently expired are returned.- Parameters:
moduleId- a moduleId- Returns:
- the returned
Docetlist - Throws:
NullArgumentException-moduleIdisnullOperationFailedException- unable to complete requestPermissionDeniedException- authorization failure- Compliance:
mandatory- This method must be implemented.
-
getDocetsForModuleOnDate
DocetList getDocetsForModuleOnDate(Id moduleId, DateTime from, DateTime to) throws OperationFailedException, PermissionDeniedException Gets aDocetListfor a module effective during the entire given date range inclusive but not confined to the date range. In plenary mode, the returned list contains all known docetsor an error results. Otherwise, the returned list may contain only those docets that are accessible through this session. In effective mode, docets are returned that are currently effective. In any effective mode, effective docets and those currently expired are returned.- Parameters:
moduleId- a moduleIdfrom- s atsrting dateto- an ending date- Returns:
- the returned
Docetlist - Throws:
InvalidArgumentException-fromis greater thantoNullArgumentException-moduleId, fromortoisnullOperationFailedException- unable to complete requestPermissionDeniedException- authorization failure- Compliance:
mandatory- This method must be implemented.
-
getDocetsForActivityUnit
DocetList getDocetsForActivityUnit(Id activityUnitId) throws OperationFailedException, PermissionDeniedException Gets aDocetListfor the given activity unitId. In plenary mode, the returned list contains all known docetsor an error results. Otherwise, the returned list may contain only those docets that are accessible through this session. In effective mode, docets are returned that are currently effective. In any effective mode, effective docets and those currently expired are returned.- Parameters:
activityUnitId- an activity unitId- Returns:
- the returned
Docetlist - Throws:
NullArgumentException-activityUnitIdisnullOperationFailedException- unable to complete requestPermissionDeniedException- authorization failure- Compliance:
mandatory- This method must be implemented.
-
getDocetsForActivityUnitOnDate
DocetList getDocetsForActivityUnitOnDate(Id activityUnitId, DateTime from, DateTime to) throws OperationFailedException, PermissionDeniedException Gets aDocetListfor an activity unit effective sduring the entire given date range inclusive but not confined to the date range. In plenary mode, the returned list contains all known docetsor an error results. Otherwise, the returned list may contain only those docets that are accessible through this session. In effective mode, docets are returned that are currently effective. In any effective mode, effective docets and those currently expired are returned.- Parameters:
activityUnitId- an activity unitIdfrom- s atsrting dateto- an ending date- Returns:
- the returned
Docetlist - Throws:
InvalidArgumentException-fromis greater thantoNullArgumentException-activityUnitId, from, ortoisnullOperationFailedException- unable to complete requestPermissionDeniedException- authorization failure- Compliance:
mandatory- This method must be implemented.
-
getDocetsForModuleAndActivityUnit
DocetList getDocetsForModuleAndActivityUnit(Id moduleId, Id activityUnitId) throws OperationFailedException, PermissionDeniedException Gets aDocetListfor the given module and activity unit. In plenary mode, the returned list contains all known docetsor an error results. Otherwise, the returned list may contain only those docets that are accessible through this session. In effective mode, docets are returned that are currently effective. In any effective mode, effective docets and those currently expired are returned.- Parameters:
moduleId- a moduleIdactivityUnitId- an activity unitId- Returns:
- the returned
Docetlist - Throws:
NullArgumentException-moduleIdoractivityUnitIdisnullOperationFailedException- unable to complete requestPermissionDeniedException- authorization failure- Compliance:
mandatory- This method must be implemented.
-
getDocetsForModuleAndActivityUnitOnDate
DocetList getDocetsForModuleAndActivityUnitOnDate(Id moduleId, Id activityUnitId, DateTime from, DateTime to) throws OperationFailedException, PermissionDeniedException Gets aDocetListfor a module and activity unit effective during the entire given date range inclusive but not confined to the date range. In plenary mode, the returned list contains all known docetsor an error results. Otherwise, the returned list may contain only those docets that are accessible through this session. In effective mode, docets are returned that are currently effective. In any effective mode, effective docets and those currently expired are returned.- Parameters:
moduleId- a moduleIdactivityUnitId- an activity unitIdfrom- s atsrting dateto- an ending date- Returns:
- the returned
Docetlist - Throws:
InvalidArgumentException-fromis greater thantoNullArgumentException-moduleId, activityUnitId, from, ortoisnullOperationFailedException- unable to complete requestPermissionDeniedException- authorization failure- Compliance:
mandatory- This method must be implemented.
-
getDocets
Gets allDocets. In plenary mode, the returned list contains all known docetsor an error results. Otherwise, the returned list may contain only those docets that are accessible through this session. In effective mode, docets are returned that are currently effective. In any effective mode, effective docets and those currently expired are returned.- Returns:
- a list of
Docets - Throws:
OperationFailedException- unable to complete requestPermissionDeniedException- authorization failure- Compliance:
mandatory- This method must be implemented.
-