OSID Logo
OSID Specifications
metering package
Version 3.1.0
Interfaceosid.metering.MeterReadingSession
Implementsosid.OsidSession
Used Byosid.metering.MeteringManager
osid.metering.MeteringProxyManager
Description

This session is used to read meters.

This reading session defines several views:

  • comparative view: elements may be silently omitted or re-ordered
  • plenary view: provides a complete result set or is an error condition
  • federated utility view: includes meters in utilities which are children of this utility in the utility hierarchy
  • isolated utility view: restricts lookups to this utility only
MethodgetUtilityId
Description

Gets the Utility Id associated with this session.

Returnosid.id.Id the Utility Id associated with this session
Compliancemandatory This method must be implemented.
MethodgetUtility
Description

Gets the Utility associated with this session.

Returnosid.metering.Utility the utility
ErrorsOPERATION_FAILED unable to complete request
PERMISSION_DENIED authorization failure
Compliancemandatory This method must be implemented.
MethodcanReadMeters
Description

Tests if this user can read meters. 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 opt not to offer metering operations.

Returnboolean false if metering methods are not authorized, true otherwise
Compliancemandatory This method must be implemented.
MethoduseComparativeMeterView
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.

Compliancemandatory This method is must be implemented.
MethodusePlenaryMeterView
Description

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

Compliancemandatory This method is must be implemented.
MethoduseFederatedUtilityView
Description

Federates the view for methods in this session. A federated view will include meters in utilities which are children of this utility in the utility hierarchy.

Compliancemandatory This method is must be implemented.
MethoduseIsolatedUtilityView
Description

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

Compliancemandatory This method is must be implemented.
MethodreadMeter
Description

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

Parametersosid.id.IdmeterId the Id of the Meter to retrieve
osid.id.IdmeteredObjectId the Id of the Metered to retrieve
Returnosid.metering.Reading the meter reading
ErrorsNOT_FOUND no Meter found with the given Id
NULL_ARGUMENT meterId is null
OPERATION_FAILED unable to complete request
PERMISSION_DENIED authorization failure
Compliancemandatory This method must be implemented.
MethodreadMeters
Description

Gets a ReadingList corresponding to the given meterdId and metered object list In plenary mode, the returned list contains all of the readings 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 readings may be omitted from the list and may present the elements in any order including returning a unique set.

Parametersosid.id.IdmeterId the Id of the Meter to retrieve
osid.id.IdListmeteredObjectIds the Ids of the metered objects to retrieve
Returnosid.metering.ReadingList the returned Reading list
ErrorsNOT_FOUND meterId or an Id was not found
NULL_ARGUMENT meterId or meteredObjectIds is null
OPERATION_FAILED unable to complete request
PERMISSION_DENIED authorization failure
Compliancemandatory This method must be implemented.