public interface ResourceLocationSession extends OsidSession
This session defines methods to look up resources on a map.
Modifier and Type | Method and Description |
---|---|
boolean |
canAccessResourceLocations()
Tests if this user can access the locations of resources.
|
Map |
getMap()
Gets the
Map associated with this session. |
Id |
getMapId()
Gets the
Map Id associated with this
session. |
ResourceLocation |
getResourceLocation(Id resourceId)
Gets the current closest bounding location of the given resource.
|
ResourceLocationList |
getResourceLocations(IdList resourceIds)
Gets the current closest bounding locations of the given resources.
|
ResourceLocationList |
getResourcesAtLocation(Id locationId)
Gets the current resources at or within the given location.
|
ResourceLocationList |
getResourcesAtLocationByGenusType(Id locationId,
Type resourceGenusType)
Gets the current resources at or within the given location for a
resource genus type.
|
ResourceLocationList |
getResourcesAtSpatialUnit(SpatialUnit spatialUnit)
Gets the current resource within the given spatial unit.
|
ResourceLocationList |
getResourcesAtSpatialUnitByGenusType(SpatialUnit spatialUnit,
Type resourceGenusType)
Gets the current resource within the given spatial unit for a given
resource genus type.
|
void |
useComparativeResourceLocationView()
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 |
useFederatedMapView()
Federates the view for methods in this session.
|
void |
useIsolatedMapView()
Isolates the view for methods in this session.
|
void |
usePlenaryResourceLocationView()
A complete view of the
Location returns is desired. |
getAuthenticatedAgent, getAuthenticatedAgentId, getClockRate, getDate, getEffectiveAgent, getEffectiveAgentId, getFormatType, getLocale, isAuthenticated, startTransaction, supportsTransactions
close
Id getMapId()
Map
Id
associated with this
session. Map Id
associated with this sessionmandatory
- This method must be implemented. Map getMap() throws OperationFailedException, PermissionDeniedException
Map
associated with this session.OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. boolean canAccessResourceLocations()
PERMISSION_DENIED.
This is intended as a hint to an
application that may not offer location operations to unauthorized
users. false
if location methods are not authorized,
true
otherwisemandatory
- This method must be implemented. void useComparativeResourceLocationView()
mandatory
- This method is must be implemented. void usePlenaryResourceLocationView()
Location
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. void useFederatedMapView()
mandatory
- This method is must be implemented. void useIsolatedMapView()
mandatory
- This method is must be implemented. ResourceLocation getResourceLocation(Id resourceId) throws NotFoundException, OperationFailedException, PermissionDeniedException
resourceId
- a resource Id
NotFoundException
- resourceId
is not on
mapNullArgumentException
- resourceId
is
null
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. ResourceLocationList getResourceLocations(IdList resourceIds) throws NotFoundException, OperationFailedException, PermissionDeniedException
resourceIds
- a resource listNotFoundException
- a resource Id
is not
on mapNullArgumentException
- resourceIds
is
null
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. ResourceLocationList getResourcesAtLocation(Id locationId) throws NotFoundException, OperationFailedException, PermissionDeniedException
locationId
- a location Id
NotFoundException
- locationId
not foundNullArgumentException
- locationId
is
null
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. ResourceLocationList getResourcesAtLocationByGenusType(Id locationId, Type resourceGenusType) throws NotFoundException, OperationFailedException, PermissionDeniedException
locationId
- a location Id
resourceGenusType
- a resource genus typeNotFoundException
- locationId
not foundNullArgumentException
- locationId
or
resourceGenusType
is null
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. ResourceLocationList getResourcesAtSpatialUnit(SpatialUnit spatialUnit) throws OperationFailedException, PermissionDeniedException
spatialUnit
- a spatial unitNullArgumentException
- spatialUnit
is
null
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. ResourceLocationList getResourcesAtSpatialUnitByGenusType(SpatialUnit spatialUnit, Type resourceGenusType) throws OperationFailedException, PermissionDeniedException
spatialUnit
- a spatial unitresourceGenusType
- a resource genus typeNullArgumentException
- spatialUnit
or
resourceGenusType
is null
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented.