| Interface | osid.mapping.LocationAdminSession | ||
|---|---|---|---|
| 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 | getMapId | ||
| Description | 
                     Gets the   | ||
| Return | osid.id.Id | the  Map Id  associated with this session  | |
| Compliance | mandatory | This method must be implemented. | |
| Method | getMap | ||
| Description | 
                     Gets the   | ||
| Return | osid.mapping.Map | the map | |
| Errors | OPERATION_FAILED | unable to complete request | |
| PERMISSION_DENIED | authorization failure | ||
| Compliance | mandatory | This method must be implemented. | |
| Method | canCreateLocations | ||
| Description | 
                     Tests if this user can create   | ||
| Return | boolean |  false  if  Location  creation is not authorized, 
 true  otherwise  | |
| Compliance | mandatory | This method must be implemented. | |
| Method | canCreateLocationWithRecordTypes | ||
| Description | 
                     Tests if this user can create a single   | ||
| Parameters | osid.type.Type[] | locationRecordTypes | array of location record types | 
| Return | boolean |  true  if  Location  creation using the specified 
record  Types  is supported,  false  otherwise  | |
| Errors | NULL_ARGUMENT |  locationRecordTypes  is  null   |                 |
| Compliance | mandatory | This method must be implemented. | |
| Method | getLocationFormForCreate | ||
| Description | 
                     Gets the location form for creating new locations. A new form should be requested for each create transaction.  | ||
| Parameters | osid.type.Type[] | locationRecordTypes | array of location record types | 
| Return | osid.mapping.LocationForm | the location form | |
| Errors | NULL_ARGUMENT |  locationRecordTypes  is  null   |                 |
| OPERATION_FAILED | unable to complete request | ||
| PERMISSION_DENIED | authorization failure | ||
| UNSUPPORTED | unable to get a form with given record types | ||
| Compliance | mandatory | This method must be implemented. | |
| Method | createLocation | ||
| Description | 
                     Creates a new   | ||
| Parameters | osid.mapping.LocationForm | locationForm | the form for this  Location   | 
| Return | osid.mapping.Location | the new  Location   | |
| Errors | ILLEGAL_STATE |  locationForm  already used in a create transaction  |                 |
| INVALID_ARGUMENT | one or more of the form elements is invalid | ||
| NULL_ARGUMENT |  locationForm  is  null   |                 ||
| OPERATION_FAILED | unable to complete request | ||
| PERMISSION_DENIED | authorization failure | ||
| UNSUPPORTED |  locationForm  did not originate from  
getLocationFormForCreate()   |                 ||
| Compliance | mandatory | This method must be implemented. | |
| Method | canUpdateLocations | ||
| Description | 
                     Tests if this user can update   | ||
| Return | boolean |  false  if  Location  modification is not 
authorized,  true  otherwise  | |
| Compliance | mandatory | This method must be implemented. | |
| Method | getLocationFormForUpdate | ||
| Description | 
                     Gets the location form for updating an existing location. A new location form should be requested for each update transaction.  | ||
| Parameters | osid.id.Id | locationId | the  Id  of the  Location   | 
| Return | osid.mapping.LocationForm | the location form | |
| Errors | NOT_FOUND |  locationId  is not found  |                 |
| NULL_ARGUMENT |  locationId  is  null   |                 ||
| OPERATION_FAILED | unable to complete request | ||
| PERMISSION_DENIED | authorization failure | ||
| Compliance | mandatory | This method must be implemented. | |
| Method | updateLocation | ||
| Description | 
                     Updates an existing location.  | ||
| Parameters | osid.mapping.LocationForm | locationForm | the form containing the elements to be updated | 
| Errors | ILLEGAL_STATE |  locationForm  already used in an update transaction  |                 |
| INVALID_ARGUMENT | the form contains an invalid value | ||
| NULL_ARGUMENT |  locationId  or  locationForm  is  null 
  |                 ||
| OPERATION_FAILED | unable to complete request | ||
| PERMISSION_DENIED | authorization failure | ||
| UNSUPPORTED |  locationForm  did not originate from  
getLocationFormForUpdate()   |                 ||
| Compliance | mandatory | This method must be implemented. | |
| Method | canDeleteLocations | ||
| Description | 
                     Tests if this user can delete   | ||
| Return | boolean |  false  if  Location  deletion is not authorized, 
 true  otherwise  | |
| Compliance | mandatory | This method must be implemented. | |
| Method | deleteLocation | ||
| Description | 
                     Deletes a   | ||
| Parameters | osid.id.Id | locationId | the  Id  of the  Location  to remove  | 
| Errors | NOT_FOUND |  locationId  not found  |                 |
| NULL_ARGUMENT |  locationId  is  null   |                 ||
| OPERATION_FAILED | unable to complete request | ||
| PERMISSION_DENIED | authorization failure | ||
| Compliance | mandatory | This method must be implemented. | |
| Method | canManageLocationAliases | ||
| Description | 
                     Tests if this user can manage   | ||
| Return | boolean |  false  if  Location  aliasing is not authorized, 
 true  otherwise  | |
| Compliance | mandatory | This method must be implemented. | |
| Method | aliasLocation | ||
| Description | 
                     Adds an   | ||
| Parameters | osid.id.Id | locationId | the  Id  of a  Location   | 
osid.id.Id | aliasId | the alias  Id   | |
| Errors | ALREADY_EXISTS |  aliasId  is already assigned  |                 |
| NOT_FOUND |  locationId  not found  |                 ||
| NULL_ARGUMENT |  locationId  or  aliasId  is  null   |                 ||
| OPERATION_FAILED | unable to complete request | ||
| PERMISSION_DENIED | authorization failure | ||
| Compliance | mandatory | This method must be implemented. | |