public interface LogLookupSession extends OsidSession
This session provides methods for retrieving Log
objects. The Log
represents a collection of log entries.
This session defines views that offer differing behaviors when retrieving multiple objects.
Generally, the comparative view should be used for most applications
as it permits operation even if there is data that cannot be accessed. For
example, a browsing application may only need to examine the Logs
it can access, without breaking execution. However, an assessment
may only be useful if all Logs
referenced by it are
available, and a test-taking applicationmay sacrifice some
interoperability for the sake of precision.
Modifier and Type | Method and Description |
---|---|
boolean |
canLookupLogs()
Tests if this user can perform
Log lookups. |
Log |
getLog(Id logId)
Gets the
Log specified by its Id. |
LogList |
getLogs()
Gets all
Logs. |
LogList |
getLogsByGenusType(Type logGenusType)
Gets a
LogList corresponding to the given log genus
Type which does not include logs of genus types derived
from the specified Type. |
LogList |
getLogsByIds(IdList logIds)
Gets a
LogList corresponding to the given
IdList. |
LogList |
getLogsByParentGenusType(Type logGenusType)
Gets a
LogList corresponding to the given log genus
Type and include any additional logs with genus types
derived from the specified Type. |
LogList |
getLogsByProvider(Id resourceId)
Gets a
LogList for a given provider. |
LogList |
getLogsByRecordType(Type logRecordType)
Gets a
LogList containing the given log record
Type. |
void |
useComparativeLogView()
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 |
usePlenaryLogView()
A complete view of the
Log returns is desired. |
getAuthenticatedAgent, getAuthenticatedAgentId, getClockRate, getDate, getEffectiveAgent, getEffectiveAgentId, getFormatType, getLocale, isAuthenticated, startTransaction, supportsTransactions
close
boolean canLookupLogs()
Log
lookups. A return of
true does not guarantee successful authorization. A return of false
indicates that it is known all 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 lookup operations to
unauthorized users. false
if lookup methods are not authorized,
true
otherwisemandatory
- This method must be implemented. void useComparativeLogView()
mandatory
- This method is must be implemented. void usePlenaryLogView()
Log
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. Log getLog(Id logId) throws NotFoundException, OperationFailedException, PermissionDeniedException
Log
specified by its Id.
In
plenary mode, the exact Id
is found or a
NOT_FOUND
results. Otherwise, the returned Log
may have a different Id
than requested, such as the
case where a duplicate Id
was assigned to a Log
and retained for compatibility.logId
- Id
of the Log
NotFoundException
- logId
not foundNullArgumentException
- logId
is
null
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method is must be implemented. LogList getLogsByIds(IdList logIds) throws NotFoundException, OperationFailedException, PermissionDeniedException
LogList
corresponding to the given
IdList.
In plenary mode, the returned list contains all of the
logs 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 Logs
may be omitted from the list and may
present the elements in any order including returning a unique set.logIds
- the list of Ids
to retrieve Log list
NotFoundException
- an Id was
not foundNullArgumentException
- logIds
is
null
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. LogList getLogsByGenusType(Type logGenusType) throws OperationFailedException, PermissionDeniedException
LogList
corresponding to the given log genus
Type
which does not include logs of genus types derived
from the specified Type.
In plenary mode, the returned
list contains all known logs or an error results. Otherwise, the
returned list may contain only those logs that are accessible through
this session.logGenusType
- a log genus type Log list
NullArgumentException
- logGenusType
is
null
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. LogList getLogsByParentGenusType(Type logGenusType) throws OperationFailedException, PermissionDeniedException
LogList
corresponding to the given log genus
Type
and include any additional logs with genus types
derived from the specified Type.
In plenary mode, the
returned list contains all known logs or an error results. Otherwise,
the returned list may contain only those logs that are accessible
through this session.logGenusType
- a log genus type Log list
NullArgumentException
- logGenusType
is
null
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. LogList getLogsByRecordType(Type logRecordType) throws OperationFailedException, PermissionDeniedException
LogList
containing the given log record
Type.
In plenary mode, the returned list contains all known
logs or an error results. Otherwise, the returned list may contain
only those logs that are accessible through this session.logRecordType
- a log record type Log list
NullArgumentException
- logRecordType
is
null
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. LogList getLogsByProvider(Id resourceId) throws OperationFailedException, PermissionDeniedException
LogList
for a given provider.
In
plenary mode, the returned list contains all known logs or an error
results. Otherwise, the returned list may contain only those logs that
are accessible through this session.resourceId
- a resource Id
Log list
NullArgumentException
- resourceId
is
null
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. LogList getLogs() throws OperationFailedException, PermissionDeniedException
Logs.
In plenary mode, the returned list
contains all known logs or an error results. Otherwise, the returned
list may contain only those logs that are accessible through this
session. Logs
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented.