public interface MeterUtilitySession extends OsidSession
This session provides methods to retrieve Meter
to
Utility
mappings. A Meter
may appear in
multiple Utility
objects. Each catalog may have its own
authorizations governing who is allowed to look at it.
This lookup session defines several views:
Modifier and Type | Method and Description |
---|---|
boolean |
canLookupMeterUtilityMappings()
Tests if this user can perform lookups of meter/utility mappings.
|
IdList |
getMeterIdsByUtilities(IdList utilityIds)
Gets the list of
Meter Ids corresponding to a list of
Utility objects. |
IdList |
getMeterIdsByUtility(Id utilityId)
Gets the list of
Meter Ids associated with a
Utility. |
MeterList |
getMetersByUtilities(IdList utilityIds)
Gets the list of
Meters corresponding to a list of
Utility objects. |
MeterList |
getMetersByUtility(Id utilityId)
Gets the list of
Meters associated with a
Utility. |
UtilityList |
getUtilitiesByMeter(Id meterId)
Gets the
Utility objects mapped to a Meter. |
IdList |
getUtilityIdsByMeter(Id meterId)
Gets the
Utility Ids mapped to a
Meter. |
void |
useComparativeUtilityView()
The returns from the lookup methods may omit or translate elements
based on this session, such as authorization, and not result in an
error.
|
void |
usePlenaryUtilityView()
A complete view of the
Meter and Utility
returns is desired. |
getAuthenticatedAgent, getAuthenticatedAgentId, getClockRate, getDate, getEffectiveAgent, getEffectiveAgentId, getFormatType, getLocale, isAuthenticated, startTransaction, supportsTransactions
close
boolean canLookupMeterUtilityMappings()
PERMISSION_DENIED.
This is intended as
a hint to an application that may opt not to offer lookup operations
to unauthorized users. false
if looking up mappings is not authorized,
true
otherwisemandatory
- This method must be implemented. void useComparativeUtilityView()
mandatory
- This method is must be implemented. void usePlenaryUtilityView()
Meter
and Utility
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.mandatory
- This method is must be implemented. IdList getMeterIdsByUtility(Id utilityId) throws NotFoundException, OperationFailedException, PermissionDeniedException
Meter Ids
associated with a
Utility.
utilityId
- Id
of the Utility
Ids
NotFoundException
- utilityId
is not
foundNullArgumentException
- utilityId
is
null
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. MeterList getMetersByUtility(Id utilityId) throws NotFoundException, OperationFailedException, PermissionDeniedException
Meters
associated with a
Utility.
utilityId
- Id
of the Utility
NotFoundException
- utilityId
is not
foundNullArgumentException
- utilityId
is
null
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. IdList getMeterIdsByUtilities(IdList utilityIds) throws OperationFailedException, PermissionDeniedException
Meter Ids
corresponding to a list of
Utility
objects.utilityIds
- list of utility Ids
Ids
NullArgumentException
- utilityIds
is
null
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. MeterList getMetersByUtilities(IdList utilityIds) throws OperationFailedException, PermissionDeniedException
Meters
corresponding to a list of
Utility
objects.utilityIds
- list of utility Ids
NullArgumentException
- utilityIds
is
null
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. IdList getUtilityIdsByMeter(Id meterId) throws NotFoundException, OperationFailedException, PermissionDeniedException
Utility
Ids
mapped to a
Meter.
meterId
- Id
of a Meter
Ids
NotFoundException
- meterId
is not foundNullArgumentException
- meterId
is
null
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. UtilityList getUtilitiesByMeter(Id meterId) throws NotFoundException, OperationFailedException, PermissionDeniedException
Utility
objects mapped to a Meter.
meterId
- Id
of a Meter
Ids
NotFoundException
- meterId
is not foundNullArgumentException
- meterId
is
null
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented.