public interface StockQuerySession extends OsidSession
This session provides methods for searching among Stock
objects. The search query is constructed using the StockQuery.
This session defines views that offer differing behaviors for searching.
Stocks may have a query record indicated by their respective query
record types. The query record is accessed via the StockQuery.
Modifier and Type | Method and Description |
---|---|
boolean |
canSearchStocks()
Tests if this user can perform
Stock lookups. |
StockQuery |
getStockQuery()
Gets a stock query.
|
StockList |
getStocksByQuery(StockQuery stockQuery)
Gets a list of
Stocks matching the given stock query. |
Warehouse |
getWarehouse()
Gets the
Warehouse associated with this session. |
Id |
getWarehouseId()
Gets the
Warehouse Id associated with
this session. |
void |
useFederatedWarehouseView()
Federates the view for methods in this session.
|
void |
useIsolatedWarehouseView()
Isolates the view for methods in this session.
|
getAuthenticatedAgent, getAuthenticatedAgentId, getClockRate, getDate, getEffectiveAgent, getEffectiveAgentId, getFormatType, getLocale, isAuthenticated, startTransaction, supportsTransactions
close
Id getWarehouseId()
Warehouse
Id
associated with
this session. Warehouse Id
associated with this sessionmandatory
- This method must be implemented. Warehouse getWarehouse() throws OperationFailedException, PermissionDeniedException
Warehouse
associated with this session.OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. boolean canSearchStocks()
Stock
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 not offer lookup operations to unauthorized
users. false
if search methods are not authorized,
true
otherwisemandatory
- This method must be implemented. void useFederatedWarehouseView()
mandatory
- This method is must be implemented. void useIsolatedWarehouseView()
mandatory
- This method is must be implemented. StockQuery getStockQuery()
mandatory
- This method must be implemented. StockList getStocksByQuery(StockQuery stockQuery) throws OperationFailedException, PermissionDeniedException
Stocks
matching the given stock query.stockQuery
- the stock query StockList
NullArgumentException
- stockQuery
is
null
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failureUnsupportedException
- stockQuery
is not
of this servicemandatory
- This method must be implemented.