public interface PriceScheduleStoreAssignmentSession extends OsidSession
This session provides methods to re-assign PriceSchedules
to Stores.
A Price
may map to
multiple Stores
and removing the last reference to a
PriceSchedule
is the equivalent of deleting it. Each Store
may have its own authorizations governing who is allowed to
operate on it.
Adding a reference of a PriceSchedule
to another
Store
is not a copy operation (eg: does not change its Id
).
Modifier and Type | Method and Description |
---|---|
void |
assignPriceScheduleToStore(Id pricScheduleeId,
Id storeId)
Adds an existing
PriceSchedule to a Store. |
boolean |
canAssignPriceSchedules()
Tests if this user can alter price schedule/store mappings.
|
boolean |
canAssignPriceSchedulesToStore(Id storeId)
Tests if this user can alter price schedule/store mappings.
|
IdList |
getAssignableStoreIds(Id storeId)
Gets a list of stores including and under the given store node in
which any price schedule can be assigned.
|
IdList |
getAssignableStoreIdsForPriceSchedule(Id storeId,
Id priceScheduleId)
Gets a list of stores including and under the given store node in
which a specific price schedule can be assigned.
|
void |
unassignPriceScheduleFromStore(Id priceScheduleId,
Id storeId)
Removes a
PriceSchedule from a Store. |
getAuthenticatedAgent, getAuthenticatedAgentId, getClockRate, getDate, getEffectiveAgent, getEffectiveAgentId, getFormatType, getLocale, isAuthenticated, startTransaction, supportsTransactions
close
boolean canAssignPriceSchedules()
PERMISSION_DENIED.
This is intended as a hint to
an application that may opt not to offer assignment operations to
unauthorized users. false
if mapping is not authorized, true
otherwisemandatory
- This method must be implemented. boolean canAssignPriceSchedulesToStore(Id storeId)
PERMISSION_DENIED.
This is intended as a hint to
an application that may opt not to offer lookup assignment to
unauthorized users.storeId
- the Id
of the Store
false
if mapping is not authorized, true
otherwiseNullArgumentException
- storeId
is
null
mandatory
- This method must be implemented. IdList getAssignableStoreIds(Id storeId) throws OperationFailedException
storeId
- the Id
of the Store
Ids
NullArgumentException
- storeId
is
null
OperationFailedException
- unable to complete requestmandatory
- This method must be implemented. IdList getAssignableStoreIdsForPriceSchedule(Id storeId, Id priceScheduleId) throws OperationFailedException
storeId
- the Id
of the Store
priceScheduleId
- the Id
of the
PriceSchedule
Ids
NullArgumentException
- storeId
or
priceScheduleId
is null
OperationFailedException
- unable to complete requestmandatory
- This method must be implemented. void assignPriceScheduleToStore(Id pricScheduleeId, Id storeId) throws AlreadyExistsException, NotFoundException, OperationFailedException, PermissionDeniedException
PriceSchedule
to a Store.
pricScheduleeId
- the Id
of the
PriceSchedule
storeId
- the Id
of the Store
AlreadyExistsException
- priceScheduleId
is already assigned to storeId
NotFoundException
- priceScheduleId
or
storeId
not foundNullArgumentException
- priceScheduleId
or storeId
is null
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. void unassignPriceScheduleFromStore(Id priceScheduleId, Id storeId) throws NotFoundException, OperationFailedException, PermissionDeniedException
PriceSchedule
from a Store.
priceScheduleId
- the Id
of the
PriceSchedule
storeId
- the Id
of the Store
NotFoundException
- priceScheduleId
or
storeId
not found or priceScheduleId
not assigned to storeId
NullArgumentException
- priceScheduleId
or storeId
is null
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented.