| Interface | osid.billing.payment.PaymentAdminSession | ||
|---|---|---|---|
| Implements | osid.OsidSession | ||
| Description | 
                 This session creates, updates, and deletes   Create and update operations differ in their usage. To 
                create a   For updates,   The delete operations delete   This session includes an   | ||
| Method | getBusinessId | ||
| Description | 
                     Gets the   | ||
| Return | osid.id.Id | the  Business Id  associated with this session  | |
| Compliance | mandatory | This method must be implemented. | |
| Method | getBusiness | ||
| Description | 
                     Gets the   | ||
| Return | osid.billing.Business | the business | |
| Errors | OPERATION_FAILED | unable to complete request | |
| PERMISSION_DENIED | authorization failure | ||
| Compliance | mandatory | This method must be implemented. | |
| Method | canCreatePayments | ||
| Description | 
                     Tests if this user can create   | ||
| Return | boolean |  false  if  Payment  creation is not authorized, 
 true  otherwise  | |
| Compliance | mandatory | This method must be implemented. | |
| Method | canCreatePaymentWithRecordTypes | ||
| Description | 
                     Tests if this user can create a single   | ||
| Parameters | osid.type.Type[] | paymentRecordTypes | array of payment record types | 
| Return | boolean |  true  if  Payment  creation using the specified 
record  Types  is supported,  false  otherwise  | |
| Errors | NULL_ARGUMENT |  paymentRecordTypes  is  null   |                 |
| Compliance | mandatory | This method must be implemented. | |
| Method | getPaymentFormForCreate | ||
| Description | 
                     Gets the payer form for creating new payments. A new form should be requested for each create transaction.  | ||
| Parameters | osid.id.Id | payerId | the Id of the associated  Payer   | 
osid.id.Id | customerId | the Id of the associated  Customer   | |
osid.type.Type[] | paymentRecordTypes | array of payment record types | |
| Return | osid.billing.payment.PaymentForm | the payment form | |
| Errors | NOT_FOUND |  payerId  or  customerId  not found  |                 |
| NULL_ARGUMENT |  payerId, customerId,  or  paymentRecordTypes  is 
 null   |                 ||
| OPERATION_FAILED | unable to complete request | ||
| PERMISSION_DENIED | authorization failure | ||
| UNSUPPORTED | unable to get form for requested record types | ||
| Compliance | mandatory | This method must be implemented. | |
| Method | createPayment | ||
| Description | 
                     Creates a new   | ||
| Parameters | osid.billing.payment.PaymentForm | paymentForm | the form for this  Payment   | 
| Return | osid.billing.payment.Payment | the new  Payment   | |
| Errors | ILLEGAL_STATE |  paymentForm  already used in a create transaction  |                 |
| INVALID_ARGUMENT | one or more of the form elements is invalid | ||
| NULL_ARGUMENT |  paymentForm  is  null   |                 ||
| OPERATION_FAILED | unable to complete request | ||
| PERMISSION_DENIED | authorization failure | ||
| UNSUPPORTED |  entryForm did not originate from getPaymentFormForCreate()   |                 ||
| Compliance | mandatory | This method must be implemented. | |
| Method | canUpdatePayments | ||
| Description | 
                     Tests if this user can update   | ||
| Return | boolean |  false  if  Payment  modification is not 
authorized,  true  otherwise  | |
| Compliance | mandatory | This method must be implemented. | |
| Method | getPaymentFormForUpdate | ||
| Description | 
                     Gets the payment form for updating an existing payment. A new payment form should be requested for each update transaction.  | ||
| Parameters | osid.id.Id | paymentId | the  Id  of the  Payment   | 
| Return | osid.billing.payment.PaymentForm | the payment form | |
| Errors | NOT_FOUND |  paymentId  is not found  |                 |
| NULL_ARGUMENT |  paymentId  is  null   |                 ||
| OPERATION_FAILED | unable to complete request | ||
| PERMISSION_DENIED | authorization failure | ||
| Compliance | mandatory | This method must be implemented. | |
| Method | updatePayment | ||
| Description | 
                     Updates an existing payment.  | ||
| Parameters | osid.billing.payment.PaymentForm | paymentForm | the form containing the elements to be updated | 
| Errors | ILLEGAL_STATE |  paymentForm  already used in an update transaction  |                 |
| INVALID_ARGUMENT | the form contains an invalid value | ||
| NULL_ARGUMENT |  paymentForm  is  null   |                 ||
| OPERATION_FAILED | unable to complete request | ||
| PERMISSION_DENIED | authorization failure | ||
| UNSUPPORTED |  entryForm did not originate from getPaymentFormForUpdate()   |                 ||
| Compliance | mandatory | This method must be implemented. | |
| Method | canDeletePayments | ||
| Description | 
                     Tests if this user can delete   | ||
| Return | boolean |  false  if  Payment  deletion is not authorized, 
 true  otherwise  | |
| Compliance | mandatory | This method must be implemented. | |
| Method | deletePayment | ||
| Description | 
                     Deletes a   | ||
| Parameters | osid.id.Id | paymentId | the  Id  of the  Payment  to remove  | 
| Errors | NOT_FOUND |  paymentId  not found  |                 |
| NULL_ARGUMENT |  paymentId  is  null   |                 ||
| OPERATION_FAILED | unable to complete request | ||
| PERMISSION_DENIED | authorization failure | ||
| Compliance | mandatory | This method must be implemented. | |
| Method | canManagePaymentAliases | ||
| Description | 
                     Tests if this user can manage   | ||
| Return | boolean |  false  if  Payment  aliasing is not authorized, 
 true  otherwise  | |
| Compliance | mandatory | This method must be implemented. | |
| Method | aliasPayment | ||
| Description | 
                     Adds an   | ||
| Parameters | osid.id.Id | paymentId | the  Id  of a  Payment   | 
osid.id.Id | aliasId | the alias  Id   | |
| Errors | ALREADY_EXISTS |  aliasId  is in use as a primary  Id   |                 |
| NOT_FOUND |  paymentId  not found  |                 ||
| NULL_ARGUMENT |  paymentId  or  aliasId  is  null   |                 ||
| OPERATION_FAILED | unable to complete request | ||
| PERMISSION_DENIED | authorization failure | ||
| Compliance | mandatory | This method must be implemented. | |