public interface CreditBillingSession extends OsidSession
This session provides methods to retrieve Credit
to
Billing
mappings. A Credit
may appear in
multiple Billings.
Each Billing
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 |
canLookupCreditBillingMappings()
Tests if this user can perform lookups of credit/billing mappings.
|
IdList |
getBillingIdsByCredit(Id creditId)
Gets the list of
Billing Ids mapped to a
Credit. |
BillingList |
getBillingsByCredit(Id creditId)
Gets the list of
Billing objects mapped to a
Credit. |
IdList |
getCreditIdsByBilling(Id billingId)
Gets the list of Credit Ids associated with a
Billing. |
IdList |
getCreditIdsByBillings(IdList billingIds)
Gets the list of
Credit Ids corresponding to a list of
Billing objects. |
CreditList |
getCreditsByBilling(Id billingId)
Gets the list of
Credits associated with a
Billing. |
CreditList |
getCreditsByBillings(IdList billingIds)
Gets the list of
Credits corresponding to a list of
Billings. |
void |
useComparativeBillingView()
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 |
usePlenaryBillingView()
A complete view of the
Credit and Billing
returns is desired. |
getAuthenticatedAgent, getAuthenticatedAgentId, getClockRate, getDate, getEffectiveAgent, getEffectiveAgentId, getFormatType, getLocale, isAuthenticated, startTransaction, supportsTransactions
close
boolean canLookupCreditBillingMappings()
PERMISSION_DENIED.
This is intendedas
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 useComparativeBillingView()
mandatory
- This method is must be implemented. void usePlenaryBillingView()
Credit
and Billing
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 getCreditIdsByBilling(Id billingId) throws NotFoundException, OperationFailedException, PermissionDeniedException
Billing.
billingId
- Id
of a Billings.
Ids
NotFoundException
- billingId
is not
foundNullArgumentException
- billingId
is
null
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. CreditList getCreditsByBilling(Id billingId) throws NotFoundException, OperationFailedException, PermissionDeniedException
Credits
associated with a
Billing.
billingId
- Id
of a Billing
NotFoundException
- billingId
is not
foundNullArgumentException
- billingId
is
null
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. IdList getCreditIdsByBillings(IdList billingIds) throws OperationFailedException, PermissionDeniedException
Credit Ids
corresponding to a list of
Billing
objects.billingIds
- list of billing Ids
Ids
NullArgumentException
- billingIds
is
null
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. CreditList getCreditsByBillings(IdList billingIds) throws OperationFailedException, PermissionDeniedException
Credits
corresponding to a list of
Billings.
billingIds
- list of billing Ids
NullArgumentException
- billingIds
is
null
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. IdList getBillingIdsByCredit(Id creditId) throws NotFoundException, OperationFailedException, PermissionDeniedException
Billing
Ids
mapped to a
Credit.
creditId
- Id
of a Credit
Ids
NotFoundException
- creditId
is not
foundNullArgumentException
- creditId
is
null
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. BillingList getBillingsByCredit(Id creditId) throws NotFoundException, OperationFailedException, PermissionDeniedException
Billing
objects mapped to a
Credit.
creditId
- Id
of a Credit
NotFoundException
- creditId
is not
foundNullArgumentException
- creditId
is
null
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented.