OSID Logo
OSID Specifications
mapping package
Version 3.1.0
Interfaceosid.mapping.LocationMapAssignmentSession
Implementsosid.OsidSession
Used Byosid.mapping.MappingManager
osid.mapping.MappingProxyManager
Description

This session provides methods to re-assign Locations to Maps. A Location may appear in multiple Maps and removing the last reference to a Location is the equivalent of deleting it. Each Map may have its own authorizations governing who is allowed to operate on it.

Adding a reference of a Location to another Map is not a copy operation (eg: does not change its Id).

MethodcanAssignLocations
Description

Tests if this user can alter location/map mappings. A return of true does not guarantee successful authorization. A return of false indicates that it is known location 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 assignment operations to unauthorized users.

Returnboolean false if location is not authorized, true otherwise
Compliancemandatory This method must be implemented.
MethodcanAssignLocationsToMap
Description

Tests if this user can alter location/map mappings. A return of true does not guarantee successful authorization. A return of false indicates that it is known location 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 assignment operations to unauthorized users.

Parametersosid.id.IdmapId the Id of the Map
Returnboolean false if mapping is not authorized, true otherwise
ErrorsNULL_ARGUMENT mapId is null
Compliancemandatory This method must be implemented.
MethodgetAssignableMapIds
Description

Gets a list of maps including and under the given map node in which any location can be assigned.

Parametersosid.id.IdmapId the Id of the Map
Returnosid.id.IdList list of assignable map Ids
ErrorsNULL_ARGUMENT mapId is null
OPERATION_FAILED unable to complete request
Compliancemandatory This method must be implemented.
MethodgetAssignableMapIdsForLocation
Description

Gets a list of maps including and under the given map node in which a specific location can be assigned.

Parametersosid.id.IdmapId the Id of the Map
osid.id.IdlocationId the Id of the Location
Returnosid.id.IdList list of assignable map Ids
ErrorsNULL_ARGUMENT mapId or locationId is null
OPERATION_FAILED unable to complete request
Compliancemandatory This method must be implemented.
MethodassignLocationToMap
Description

Adds an existing Location to a Map.

Parametersosid.id.IdlocationId the Id of the Location
osid.id.IdmapId the Id of the Map
ErrorsALREADY_EXISTS locationId is already assigned to mapId
NOT_FOUND locationId or mapId not found
NULL_ARGUMENT locationId or mapId is null
OPERATION_FAILED unable to complete request
PERMISSION_DENIED authorization failure
Compliancemandatory This method must be implemented.
MethodunassignLocationFromMap
Description

Removes a Location from a Map.

Parametersosid.id.IdlocationId the Id of the Location
osid.id.IdmapId the Id of the Map
ErrorsNOT_FOUND locationId or mapId not found or locationId not assigned to mapId
NULL_ARGUMENT locationId or mapId is null
OPERATION_FAILED unable to complete request
PERMISSION_DENIED authorization failure
Compliancemandatory This method must be implemented.
MethodreassignLocationToMap
Description

Moves a Map from one Location to another. Mappings to other Locations are unaffected.

Parametersosid.id.IdlocationId the Id of the Location
osid.id.IdfromMapId the Id of the current Map
osid.id.IdtoMapId the Id of the destination Map
ErrorsALREADY_EXISTS locationId already assigned to toMapId
NOT_FOUND locationId, fromMapId, or toMapId not found or locationId not mapped to fromMapId
NULL_ARGUMENT locationId, fromMapId, or toMapId is null
OPERATION_FAILED unable to complete request
PERMISSION_DENIED authorization failure
Compliancemandatory This method must be implemented.