public interface PositionLookupSession extends OsidSession
This session defines methods for retrieving positions.
This lookup session defines several views:
PositionAdminSession.
The methods useFederatedRealmView()
and
useIsolatedRealmView()
behave as a radio group and one should be
selected before invoking any lookup methods.
Modifier and Type | Method and Description |
---|---|
boolean |
canLookupPositions()
Tests if this user can examine this realm.
|
Position |
getPosition(Id positionId)
Gets the
Position specified by its Id. |
PositionList |
getPositions()
Gets all positions.
|
PositionList |
getPositionsByGenusType(Type positionGenusType)
Gets a
PositionList corresponding to the given position
genus Type which does not include positions of types
derived from the specified Type. |
PositionList |
getPositionsByIds(IdList positionIds)
Gets a
PositionList corresponding to the given
IdList. |
PositionList |
getPositionsByParentGenusType(Type positionGenusType)
Gets a
PositionList corresponding to the given position
genus Type and include any additional positions with
genus types derived from the specified Type. |
PositionList |
getPositionsByRecordType(Type positionRecordType)
Gets a
PositionList containing the given position
record Type. |
PositionList |
getPositionsForOrganization(Id organizationId)
Gets a
PositionList for the given organization . |
PositionList |
getPositionsForOrganizationOnDate(Id organizationId,
DateTime from,
DateTime to)
Gets a
PositionList for an organizatoon and effective
during the entire given date range inclusive but not confined to the
date range. |
PositionList |
getPositionsOnDate(DateTime from,
DateTime to)
Gets a
PositionList effective during the entire given
date range inclusive but not confined to the date range. |
Realm |
getRealm()
Gets the
Realm associated with this session. |
Id |
getRealmId()
Gets the
Realm Id associated with this
session. |
void |
useAnyEffectivePositionView()
All positions of any effective dates are returned by methods in this
session.
|
void |
useComparativePositionView()
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 |
useEffectivePositionView()
Only positions whose effective dates are current are returned by
methods in this session.
|
void |
useFederatedRealmView()
Federates the view for methods in this session.
|
void |
useIsolatedRealmView()
Isolates the view for methods in this session.
|
void |
usePlenaryPositionView()
A complete view of the
Position returns is desired. |
getAuthenticatedAgent, getAuthenticatedAgentId, getClockRate, getDate, getEffectiveAgent, getEffectiveAgentId, getFormatType, getLocale, isAuthenticated, startTransaction, supportsTransactions
close
Id getRealmId()
Realm
Id
associated with this
session. Realm Id
associated with this sessionmandatory
- This method must be implemented. Realm getRealm() throws OperationFailedException, PermissionDeniedException
Realm
associated with this session.OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. boolean canLookupPositions()
PERMISSION_DENIED.
This is intended as a hint to an
application that may opt not to offer these operations. false
if realm reading methods are not
authorized, true
otherwisemandatory
- This method must be implemented. void useComparativePositionView()
mandatory
- This method is must be implemented. void usePlenaryPositionView()
Position
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 useFederatedRealmView()
mandatory
- This method is must be implemented. void useIsolatedRealmView()
mandatory
- This method is must be implemented. void useEffectivePositionView()
mandatory
- This method is must be implemented. void useAnyEffectivePositionView()
mandatory
- This method is must be implemented. Position getPosition(Id positionId) throws NotFoundException, OperationFailedException, PermissionDeniedException
Position
specified by its Id.
In plenary mode, the exact Id
is found
or a NOT_FOUND
results. Otherwise, the returned
Position
may have a different Id
than
requested, such as the case where a duplicate Id
was
assigned to a Position
and retained for compatibility.
In effective mode, positions are returned that are currently
effective. In any effective mode, effective positions and those
currently expired are returned.positionId
- the Id
of the Position
to retrieve Position
NotFoundException
- no Position
found
with the given Id
NullArgumentException
- positionId
is
null
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. PositionList getPositionsByIds(IdList positionIds) throws NotFoundException, OperationFailedException, PermissionDeniedException
PositionList
corresponding to the given
IdList.
In plenary mode, the returned list contains all of the
positions specified in the Id
list, in the order of the
list, including duplicates, or an error results if an Id
in the supplied list is not found or inaccessible. Otherwise,
inaccessible positions may be omitted from the list and may present
the elements in any order including returning a unique set.
In effective mode, positions are returned that are currently
effective. In any effective mode, effective positions and those
currently expired are returned.positionIds
- the list of Ids
to retrieve Position list
NotFoundException
- an Id was
not foundNullArgumentException
- positionIds
is
null
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. PositionList getPositionsByGenusType(Type positionGenusType) throws OperationFailedException, PermissionDeniedException
PositionList
corresponding to the given position
genus Type
which does not include positions of types
derived from the specified Type.
In plenary mode, the returned list contains all known
positions or an error results. Otherwise, the returned list may
contain only those positions that are accessible through this session.
In effective mode, positions are returned that are currently
effective. In any effective mode, effective positions and those
currently expired are returned.positionGenusType
- a positions genus type Position list
NullArgumentException
- positionGenusType
is null
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. PositionList getPositionsByParentGenusType(Type positionGenusType) throws OperationFailedException, PermissionDeniedException
PositionList
corresponding to the given position
genus Type
and include any additional positions with
genus types derived from the specified Type.
In plenary mode, the returned list contains all known
positions or an error results. Otherwise, the returned list may
contain only those positions that are accessible through this session.
In active mode, positions are returned that are currently active. In
any status mode, active and inactive positions are returned.positionGenusType
- a position genus type Position list
NullArgumentException
- positionGenusType
is null
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. PositionList getPositionsByRecordType(Type positionRecordType) throws OperationFailedException, PermissionDeniedException
PositionList
containing the given position
record Type.
In plenary mode, the returned list contains all known positions or an
error results. Otherwise, the returned list may contain only those
positions that are accessible through this session.
In effective mode, positions are returned that are currently
effective. In any effective mode, effective positions and those
currently expired are returned.positionRecordType
- a position record type PositionList
NullArgumentException
- positionRecordType
is null
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. PositionList getPositionsOnDate(DateTime from, DateTime to) throws OperationFailedException, PermissionDeniedException
PositionList
effective during the entire given
date range inclusive but not confined to the date range.
In plenary mode, the returned list contains all known positions or an
error results. Otherwise, the returned list may contain only those
positions that are accessible through this session.
In effective mode, positions are returned that are currently
effective. In any effective mode, effective positions and those
currently expired are returned.from
- start of date rangeto
- end of date range PositionList
InvalidArgumentException
- from
is
greater than to
NullArgumentException
- from
or
to
is null
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. PositionList getPositionsForOrganization(Id organizationId) throws OperationFailedException, PermissionDeniedException
PositionList
for the given organization .
In plenary mode, the returned list contains all known positions or an
error results. Otherwise, the returned list may contain only those
positions that are accessible through this session.
In effective mode, positions are returned that are currently
effective. In any effective mode, effective positions and those
currently expired are returned.organizationId
- an organization Id
PositionList
NullArgumentException
- organizationId
is null
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. PositionList getPositionsForOrganizationOnDate(Id organizationId, DateTime from, DateTime to) throws OperationFailedException, PermissionDeniedException
PositionList
for an organizatoon and effective
during the entire given date range inclusive but not confined to the
date range.
In plenary mode, the returned list contains all known positions or an
error results. Otherwise, the returned list may contain only those
positions that are accessible through this session.
In effective mode, positions are returned that are currently
effective. In any effective mode, effective positions and those
currently expired are returned.organizationId
- an organization Id
from
- start of date rangeto
- end of date rangeInvalidArgumentException
- from
is
greater than to
NullArgumentException
- organization, from,
or to
is null
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. PositionList getPositions() throws OperationFailedException, PermissionDeniedException
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented.