| Interface | osid.provisioning.ExchangeSession | ||
|---|---|---|---|
| Implements | osid.OsidSession | ||
| Description | 
                 This session exchanges an existing provision for a request 
                for another provision via the queue. The data for create and 
                update is provided via the   | ||
| Method | getQueueId | ||
| Description | 
                     Gets the   | ||
| Return | osid.id.Id | the  Queue Id  associated with this session  | |
| Compliance | mandatory | This method must be implemented. | |
| Method | getQueue | ||
| Description | 
                     Gets the   | ||
| Return | osid.provisioning.Queue | the queue | |
| Errors | OPERATION_FAILED | unable to complete request | |
| PERMISSION_DENIED | authorization failure | ||
| Compliance | mandatory | This method must be implemented. | |
| Method | canCreateRequestsInExchange | ||
| Description | 
                     Tests if this user can create   | ||
| Parameters | osid.id.Id | provisionId | the  Id  of the provision to exchange  | 
| Return | boolean |  false  if  Request  creation is not authorized, 
 true  otherwise  | |
| Errors | NULL_ARGUMENT |  provisionId  is  null   |                 |
| Compliance | mandatory | This method must be implemented. | |
| Method | canCreateRequestWithRecordTypesInExchange | ||
| Description | 
                     Tests if this user can create a single   | ||
| Parameters | osid.id.Id | provisionId | the  Id  of the provision to exchange  | 
osid.type.Type[] | requestRecordTypes | array of request record types | |
| Return | boolean |  true  if  Request  creation using the specified 
record  Types  is supported,  false  otherwise  | |
| Errors | NULL_ARGUMENT |  provisionId  or  requestRecordTypes  is  
null   |                 |
| Compliance | mandatory | This method must be implemented. | |
| Method | getRequestFormForCreate | ||
| Description | 
                     Gets the request form for creating new requests for the exchange. A new form should be requested for each create transaction.  | ||
| Parameters | osid.id.Id | provisionId | the  Id  of the provision to exchange  | 
osid.type.Type[] | requestRecordTypes | array of request record types | |
| Return | osid.provisioning.RequestForm | the request form | |
| Errors | NOT_FOUND |  provisionId  is not found  |                 |
| NULL_ARGUMENT |  provisionId  or  requestRecordTypes  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 | createRequestInExchange | ||
| Description | 
                     Creates a new   | ||
| Parameters | osid.provisioning.RequestForm | requestForm | the form for this  Request   | 
| Return | osid.provisioning.Request | the new  Request   | |
| Errors | ILLEGAL_STATE |  requestForm  already used in a create transaction  |                 |
| INVALID_ARGUMENT | one or more of the form elements is invalid | ||
| NULL_ARGUMENT |  requestForm  is  null   |                 ||
| OPERATION_FAILED | unable to complete request | ||
| PERMISSION_DENIED | authorization failure | ||
| UNSUPPORTED |  requestForm  did not originate from  
getRequestFormForCreate()   |                 ||
| Compliance | mandatory | This method must be implemented. | |