OSID Logo
OSID Specifications
metering package
Version 3.0.0
Release Candidate Preview
Interfaceosid.metering.MeterSearchSession
Implementsosid.metering.MeterQuerySession
Description

This session provides methods for searching among meters. The search query is constructed using the MeterQuery.

getMetersByQuery() is the basic search method and returns a list of meters. A more advanced search may be performed with getMetersBySearch(). It accepts a MeterSearch in addition to the query for the purpose of specifying additional options affecting the entire search, such as ordering. getMetersBySearch() returns a MeterSearchResults that can be used to access the resulting MeterList or be used to perform a search within the result set through MeterSearch.

This session defines views that offer differing behaviors for searching.

  • federated utility view: searches include meters in utilities of which this utility is an ancestor in the utility hierarchy
  • isolated utility view: searches are restricted to meters in this utility only
MethodgetMeterSearch
Description

Gets a meter search.

Returnosid.metering.MeterSearchthe meter search
CompliancemandatoryThis method must be implemented.
MethodgetMeterSearchOrder
Description

Gets a meter search order. The MeterSearchOrder is supplied to a MeterSearch to specify the ordering of results.

Returnosid.metering.MeterSearchOrderthe meter search order
CompliancemandatoryThis method must be implemented.
MethodgetMetersBySearch
Description

Gets the search results matching the given search query using the given search.

Parametersosid.metering.MeterQuerymeterQuerythe meter query
osid.metering.MeterSearchmeterSearchthe meter search
Returnosid.metering.MeterSearchResultsthe returned search results
ErrorsNULL_ARGUMENT meterQuery or meterSearch is null
OPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
UNSUPPORTED meterQuery or meterSearch is not of this service
CompliancemandatoryThis method must be implemented.
MethodgetMeterQueryFromInspector
Description

Gets a meter query from an inspector. The inspector is available from a MeterSearchResults.

Parametersosid.metering.MeterQueryInspectormeterQueryInspectora meter query inspector
Returnosid.metering.MeterQuerythe meter query
ErrorsNULL_ARGUMENT meterQueryInspector is null
UNSUPPORTED meterQueryInspector is not of this service
CompliancemandatoryThis method must be implemented.