OSID Logo
OSID Specifications
room package
Version 3.0.0
Release Candidate Preview
Interfaceosid.room.BuildingLookupSession
Implementsosid.OsidSession
Description

This session provides methods for retrieving Building objects. The Building represents a collection of rooms.

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 set or is an error condition
  • isolated campus view: All room methods in this session operate, retrieve and pertain to buildings defined explicitly in the current campus. Using an isolated view is useful for managing buildings with the BuildingAdminSession.
  • federated campus view: All building lookup methods in this session operate, retrieve and pertain to all buildings defined in this campus and any other campuses implicitly available in this campus through campus inheritence.
  • effective building view: All building lookup methods return effective buildings.
  • any effective building view: Buildings of any effective date are returned.
MethodgetCampusId
Description

Gets the Campus Id associated with this session.

Returnosid.id.Idthe Campus Id associated with this session
CompliancemandatoryThis method must be implemented.
MethodgetCampus
Description

Gets the Campus associated with this session.

Returnosid.room.Campusthe campus
ErrorsOPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
CompliancemandatoryThis method must be implemented.
MethodcanLookupBuildings
Description

Tests if this user can perform Building lookups. 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 a PERMISSION_DENIED. This is intended as a hint to an application that may not offer lookup operations to unauthorized users.

Returnboolean false if lookup methods are not authorized, true otherwise
CompliancemandatoryThis method must be implemented.
MethoduseComparativeBuildingView
Description

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.

CompliancemandatoryThis method is must be implemented.
MethodusePlenaryBuildingView
Description

A complete view of the Building returns 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.

CompliancemandatoryThis method is must be implemented.
MethoduseFederatedCampusView
Description

Federates the view for methods in this session. A federated view will include buildings in campuses which are children of this campus in the campus hierarchy.

CompliancemandatoryThis method is must be implemented.
MethoduseIsolatedCampusView
Description

Isolates the view for methods in this session. An isolated view restricts retrievals to this campus only.

CompliancemandatoryThis method is must be implemented.
MethoduseEffectiveBuildingView
Description

Only buildings whose effective dates are current are returned by methods in this session

CompliancemandatoryThis method is must be implemented.
MethoduseAnyEffectiveBuildingView
Description

Buildings of any effective dates are returned by all methods in this session.

CompliancemandatoryThis method is must be implemented.
MethodgetBuilding
Description

Gets the Building specified by its Id.

In plenary mode, the exact Id is found or a NOT_FOUND results. Otherwise, the returned Building may have a different Id than requested, such as the case where a duplicate Id was assigned to a Building and retained for compatibility.

In effective mode, buildings are returned that are currently effective. In any effective mode, effective buildings and those currently expired are returned.

Parametersosid.id.IdbuildingId Id of the Building
Returnosid.room.Buildingthe building
ErrorsNOT_FOUND buildingId not found
NULL_ARGUMENT buildingId is null
OPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
CompliancemandatoryThis method is must be implemented.
MethodgetBuildingsByIds
Description

Gets a BuildingList corresponding to the given IdList.

In plenary mode, the returned list contains all of the buildings specified in the Id list, in the order of the list, including duplicates, or an error results if an Id in the supplied list is not found or inaccessible. Otherwise, inaccessible Buildings may be omitted from the list and may present the elements in any order including returning a unique set.

In effective mode, buildings are returned that are currently effective. In any effective mode, effective buildings and those currently expired are returned.

Parametersosid.id.IdListbuildingIdsthe list of Ids to retrieve
Returnosid.room.BuildingListthe returned Building list
ErrorsNOT_FOUNDan Id was not found
NULL_ARGUMENT buildingIds is null
OPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
CompliancemandatoryThis method must be implemented.
MethodgetBuildingsByGenusType
Description

Gets a BuildingList corresponding to the given building genus Type which does not include buildings of genus types derived from the specified Type.

In plenary mode, the returned list contains all known buildings or an error results. Otherwise, the returned list may contain only those buildings that are accessible through this session.

In effective mode, buildings are returned that are currently effective. In any effective mode, effective buildings and those currently expired are returned.

Parametersosid.type.TypebuildingGenusTypea building genus type
Returnosid.room.BuildingListthe returned Building list
ErrorsNULL_ARGUMENT buildingGenusType is null
OPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
CompliancemandatoryThis method must be implemented.
MethodgetBuildingsByParentGenusType
Description

Gets a BuildingList corresponding to the given building genus Type and include any additional buildings with genus types derived from the specified Type.

In plenary mode, the returned list contains all known buildings or an error results. Otherwise, the returned list may contain only those buildings that are accessible through this session.

In effective mode, buildings are returned that are currently effective. In any effective mode, effective buildings and those currently expired are returned.

Parametersosid.type.TypebuildingGenusTypea building genus type
Returnosid.room.BuildingListthe returned Building list
ErrorsNULL_ARGUMENT buildingGenusType is null
OPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
CompliancemandatoryThis method must be implemented.
MethodgetBuildingsByRecordType
Description

Gets a BuildingList containing the given building record Type.

In plenary mode, the returned list contains all known buildings or an error results. Otherwise, the returned list may contain only those buildings that are accessible through this session.

In effective mode, buildings are returned that are currently effective. In any effective mode, effective buildings and those currently expired are returned.

Parametersosid.type.TypebuildingRecordTypea building record type
Returnosid.room.BuildingListthe returned Building list
ErrorsNULL_ARGUMENT buildingRecordType is null
OPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
CompliancemandatoryThis method must be implemented.
MethodgetBuildingsOnDate
Description

Gets a list of all buildings effective during the entire given date range inclusive but not confined to the date range.

In plenary mode, the returned list contains all known buildings or an error results. Otherwise, the returned list may contain only those buildings that are accessible through this session.

In effective mode, buildings are returned that are currently effective. In any effective mode, effective buildings and those currently expired are returned.

Parametersosid.calendaring.DateTimefromstart of date range
osid.calendaring.DateTimetoend of date range
Returnosid.room.BuildingListthe returned Building list
ErrorsINVALID_ARGUMENT from is greater than to
NULL_ARGUMENT from or to is null
OPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
CompliancemandatoryThis method must be implemented.
MethodgetBuildingsByNumber
Description

Gets a BuildingList containing of the given building number.

In plenary mode, the returned list contains all known buildings or an error results. Otherwise, the returned list may contain only those buildings that are accessible through this session.

In effective mode, buildings are returned that are currently effective. In any effective mode, effective buildings and those currently expired are returned.

Parametersstringnumbera building number
Returnosid.room.BuildingListthe returned Building list
ErrorsNULL_ARGUMENT number is null
OPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
CompliancemandatoryThis method must be implemented.
MethodgetBuildings
Description

Gets all Buildings.

In plenary mode, the returned list contains all known buildings or an error results. Otherwise, the returned list may contain only those buildings that are accessible through this session.

In effective mode, buildings are returned that are currently effective. In any effective mode, effective buildings and those currently expired are returned.

Returnosid.room.BuildingLista list of Buildings
ErrorsOPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
CompliancemandatoryThis method must be implemented.