public interface ProvisionLookupSession extends OsidSession
This session provides methods for retrieving Provision
objects. The Provision
represents a fixed connection
between two Provisions.
This session defines views that offer differing behaviors when retrieving multiple objects.
Provisions
with the ProvisionAdminSession.
Generally, the comparative view should be used for most applications
as it permits operation even if there is data that cannot be accessed. The
methods useFederatedDistributorView()
and
useIsolatedDistributorView()
behave as a radio group and one
should be selected before invoking any lookup methods.
Modifier and Type | Method and Description |
---|---|
boolean |
canLookupProvisions()
Tests if this user can perform
Provision lookups. |
Distributor |
getDistributor()
Gets the
Distributor associated with this session. |
Id |
getDistributorId()
Gets the
Distributor Id associated with
this session. |
Provision |
getProvision(Id provisionId)
Gets the
Provision specified by its Id. |
ProvisionList |
getProvisions()
Gets all
Provisions. |
ProvisionList |
getProvisionsByGenusType(Type provisionGenusType)
Gets a
ProvisionList corresponding to the given
provision genus Type which does not include provisions
of genus types derived from the specified Type. |
ProvisionList |
getProvisionsByIds(IdList provisionIds)
Gets a
ProvisionList corresponding to the given
IdList. |
ProvisionList |
getProvisionsByParentGenusType(Type provisionGenusType)
Gets a
ProvisionList corresponding to the given
provision genus Type and include any additional
provisions with genus types derived from the specified Type. |
ProvisionList |
getProvisionsByRecordType(Type provisionRecordType)
Gets a
ProvisionList containing the given provision
record Type. |
ProvisionList |
getProvisionsForBroker(Id brokerId)
Gets a list of provisions for a supplied broker.
|
ProvisionList |
getProvisionsForBrokerOnDate(Id brokerId,
DateTime from,
DateTime to)
Gets a list of provisions for a supplied broker.
|
ProvisionList |
getProvisionsForProvisionable(Id provisionableId)
Gets a list of provisions for a provisionable.
|
ProvisionList |
getProvisionsForProvisionableAndRecipient(Id provisionableId,
Id recipientId)
Gets a list of provisions for a resource and recipient.
|
ProvisionList |
getProvisionsForProvisionableAndRecipientOnDate(Id provisionableId,
Id recipientId,
DateTime from,
DateTime to)
Gets a list of provisions for a resource and request and effective
during the entire given date range inclusive but not confined to the
date range.
|
ProvisionList |
getProvisionsForProvisionableOnDate(Id provisionableId,
DateTime from,
DateTime to)
Gets a list of provisions for a provisionable and effective during the
entire given date range inclusive but not confined to the date range.
|
ProvisionList |
getProvisionsForRecipient(Id resourceId)
Gets a list of provisions for a recipient resource.
|
ProvisionList |
getProvisionsForRecipientOnDate(Id resourceId,
DateTime from,
DateTime to)
Gets a list of provisions for a recipient resource and effective
during the entire given date range inclusive but not confined to the
date range.
|
ProvisionList |
getProvisionsForRequest(Id requestId)
Gets a list of provisions for a request.
|
ProvisionList |
getProvisionsOnDate(DateTime from,
DateTime to)
Gets a list of provisions effective during the entire given date range
inclusive but not confined to the date range.
|
void |
useAnyEffectiveProvisionView()
All provisions of any effective dates are returned by methods in this
session.
|
void |
useComparativeProvisionView()
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 |
useEffectiveProvisionView()
Only provisions whose effective dates are current are returned by
methods in this session.
|
void |
useFederatedDistributorView()
Federates the view for methods in this session.
|
void |
useIsolatedDistributorView()
Isolates the view for methods in this session.
|
void |
usePlenaryProvisionView()
A complete view of the
Provision returns is desired. |
getAuthenticatedAgent, getAuthenticatedAgentId, getClockRate, getDate, getEffectiveAgent, getEffectiveAgentId, getFormatType, getLocale, isAuthenticated, startTransaction, supportsTransactions
close
Id getDistributorId()
Distributor
Id
associated with
this session. Distributor Id
associated with this sessionmandatory
- This method must be implemented. Distributor getDistributor() throws OperationFailedException, PermissionDeniedException
Distributor
associated with this session.OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. boolean canLookupProvisions()
Provision
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 opt not to offer lookup operations to
unauthorized users. false
if lookup methods are not authorized,
true
otherwisemandatory
- This method must be implemented. void useComparativeProvisionView()
mandatory
- This method is must be implemented. void usePlenaryProvisionView()
Provision
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. void useFederatedDistributorView()
mandatory
- This method is must be implemented. void useIsolatedDistributorView()
mandatory
- This method is must be implemented. void useEffectiveProvisionView()
mandatory
- This method is must be implemented. void useAnyEffectiveProvisionView()
mandatory
- This method is must be implemented. Provision getProvision(Id provisionId) throws NotFoundException, OperationFailedException, PermissionDeniedException
Provision
specified by its Id.
In plenary mode, the exact Id
is found
or a NOT_FOUND
results. Otherwise, the returned
Provision
may have a different Id
than
requested, such as the case where a duplicate Id
was
assigned to a Provision
and retained for compatibility.
In effective mode, provisions are returned that are currently
effective. In any effective mode, effective provisions and those
currently expired are returned.provisionId
- Id
of the Provision
NotFoundException
- provisionId
not
foundNullArgumentException
- provisionId
is
null
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method is must be implemented. ProvisionList getProvisionsByIds(IdList provisionIds) throws NotFoundException, OperationFailedException, PermissionDeniedException
ProvisionList
corresponding to the given
IdList.
In plenary mode, the returned list contains all of the
provisions 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 Provisions
may be omitted from the list
and may present the elements in any order including returning a unique
set.
In effective mode, provisions are returned that are currently
effective. In any effective mode, effective provisions and those
currently expired are returned.provisionIds
- the list of Ids
to retrieve Provision
listNotFoundException
- an Id
was not foundNullArgumentException
- provisionIds
is
null
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. ProvisionList getProvisionsByGenusType(Type provisionGenusType) throws OperationFailedException, PermissionDeniedException
ProvisionList
corresponding to the given
provision genus Type
which does not include provisions
of genus types derived from the specified Type.
In plenary mode, the returned list contains all known
provisions or an error results. Otherwise, the returned list may
contain only those provisions that are accessible through this
session.
In effective mode, provisions are returned that are currently
effective. In any effective mode, effective provisions and those
currently expired are returned.provisionGenusType
- a provision genus type Provision
listNullArgumentException
- provisionGenusType
is null
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. ProvisionList getProvisionsByParentGenusType(Type provisionGenusType) throws OperationFailedException, PermissionDeniedException
ProvisionList
corresponding to the given
provision genus Type
and include any additional
provisions with genus types derived from the specified Type.
In plenary mode, the returned list contains all known
provisions or an error results. Otherwise, the returned list may
contain only those provisions that are accessible through this
session.
In effective mode, provisions are returned that are currently
effective. In any effective mode, effective provisions and those
currently expired are returned.provisionGenusType
- a provision genus type Provision
listNullArgumentException
- provisionGenusType
is null
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. ProvisionList getProvisionsByRecordType(Type provisionRecordType) throws OperationFailedException, PermissionDeniedException
ProvisionList
containing the given provision
record Type.
In plenary mode, the returned list contains all known
provisions or an error results. Otherwise, the returned list may
contain only those provisions that are accessible through this
session.
In effective mode, provisions are returned that are currently
effective. In any effective mode, effective provisions and those
currently expired are returned.provisionRecordType
- a provision record type Provision
listNullArgumentException
- provisionRecordType
is null
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. ProvisionList getProvisionsOnDate(DateTime from, DateTime to) throws OperationFailedException, PermissionDeniedException
In plenary mode, the returned list contains all known
provisions or an error results. Otherwise, the returned list may
contain only those provisions that are accessible through this
session.
In effective mode, provisions are returned that are currently
effective in addition to being effective in the guven date range. In
any effective mode, effective provisions and those currently expired
are returned.from
- start of date rangeto
- end of date range Provision
listInvalidArgumentException
- from
is
greater than to
NullArgumentException
- from
or
to
is null
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. ProvisionList getProvisionsForBroker(Id brokerId) throws OperationFailedException, PermissionDeniedException
In plenary mode, the returned list contains all known
provisions or an error results. Otherwise, the returned list may
contain only those provisions that are accessible through this
session.
In effective mode, provisions are returned that are currently
effective. In any effective mode, effective provisions and those
currently expired are returned.brokerId
- a broker Id
Provision
listNullArgumentException
- brokerId
is
null
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. ProvisionList getProvisionsForBrokerOnDate(Id brokerId, DateTime from, DateTime to) throws OperationFailedException, PermissionDeniedException
In plenary mode, the returned list contains all known
provisions or an error results. Otherwise, the returned list may
contain only those provisions that are accessible through this
session.
In effective mode, provisions are returned that are currently
effective in addition to being effective in the guven date range. In
any effective mode, effective provisions and those currently expired
are returned.brokerId
- a broker Id
from
- start of date rangeto
- end of date range Provision
listInvalidArgumentException
- from
is
greater than to
NullArgumentException
- brokerId, from
or to
is null
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. ProvisionList getProvisionsForProvisionable(Id provisionableId) throws OperationFailedException, PermissionDeniedException
provisionableId
- a provisionable Id
Provision
listNullArgumentException
- provisionableId
is null
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. ProvisionList getProvisionsForProvisionableOnDate(Id provisionableId, DateTime from, DateTime to) throws OperationFailedException, PermissionDeniedException
provisionableId
- a provisionable Id
from
- start of date rangeto
- end of date range Provision
listInvalidArgumentException
- from
is
greater than to
NullArgumentException
- provisionableId, from
or to
is null
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. ProvisionList getProvisionsForRecipient(Id resourceId) throws OperationFailedException, PermissionDeniedException
resourceId
- a resource Id
Provision
listNullArgumentException
- resourceId
is
null
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. ProvisionList getProvisionsForRecipientOnDate(Id resourceId, DateTime from, DateTime to) throws OperationFailedException, PermissionDeniedException
In plenary mode, the returned list contains all known
provisions or an error results. Otherwise, the returned list may
contain only those provisions that are accessible through this
session.
In effective mode, provisions are returned that are currently
effective in addition to being effective in the guven date range. In
any effective mode, effective provisions and those currently expired
are returned.resourceId
- a resource Id
from
- start of date rangeto
- end of date range Provision
listInvalidArgumentException
- from
is
greater than to
NullArgumentException
- resourceId, from
or to
is null
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. ProvisionList getProvisionsForProvisionableAndRecipient(Id provisionableId, Id recipientId) throws OperationFailedException, PermissionDeniedException
provisionableId
- a provisionable Id
recipientId
- a recipient resource Id
Provision
listNullArgumentException
- provisionableId
or recipientId
is null
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. ProvisionList getProvisionsForProvisionableAndRecipientOnDate(Id provisionableId, Id recipientId, DateTime from, DateTime to) throws OperationFailedException, PermissionDeniedException
provisionableId
- a provisionable Id
recipientId
- a recipient resource Id
from
- start of date rangeto
- end of date range Provision
listInvalidArgumentException
- from
is
greater than to
NullArgumentException
- provisionableId,
recipientId, from
or to
is null
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. ProvisionList getProvisionsForRequest(Id requestId) throws OperationFailedException, PermissionDeniedException
In plenary mode, the returned list contains all known
provisions or an error results. Otherwise, the returned list may
contain only those provisions that are accessible through this
session.
In effective mode, provisions are returned that are currently
effective. In any effective mode, effective provisions and those
currently expired are returned.requestId
- a request Id
Provision
listNullArgumentException
- requestId
is
null
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. ProvisionList getProvisions() throws OperationFailedException, PermissionDeniedException
Provisions.
In plenary mode, the returned list contains all known
provisions or an error results. Otherwise, the returned list may
contain only those provisions that are accessible through this
session.
In effective mode, provisions are returned that are currently
effective. In any effective mode, effective provisions and those
currently expired are returned. Provisions
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented.