public interface DemographicEnablerBinAssignmentSession extends OsidSession
This session provides methods to re-assign DemographicEnabler
to Bin
mappings. A DemographicEnabler
may appear in multiple Bin
objects and removing the
last reference to a DemographicEnabler
is the equivalent of
deleting it. Each Bin
may have its own authorizations
governing who is allowed to operate on it.
Adding a reference of a DemographicEnabler
to another
Bin
is not a copy operation (eg: does not change its
Id
).
Modifier and Type | Method and Description |
---|---|
void |
assignDemographicEnablerToBin(Id demographicEnablerId,
Id binId)
Adds an existing
DemographicEnabler to an Bin. |
boolean |
canAssignDemographicEnablers()
Tests if this user can alter demographic enabler/bin mappings.
|
boolean |
canAssignDemographicEnablersToBin(Id binId)
Tests if this user can alter demographic enabler/bin mappings.
|
IdList |
getAssignableBinIds(Id binId)
Gets a list of bins including and under the given bin node in which
any demographic enabler can be assigned.
|
IdList |
getAssignableBinIdsForDemographicEnabler(Id binId,
Id demographicEnablerId)
Gets a list of bins including and under the given bin node in which a
specific demographic enabler can be assigned.
|
void |
unassignDemographicEnablerFromBin(Id demographicEnablerId,
Id binId)
Removes a
DemographicEnabler from an Bin. |
getAuthenticatedAgent, getAuthenticatedAgentId, getClockRate, getDate, getEffectiveAgent, getEffectiveAgentId, getFormatType, getLocale, isAuthenticated, startTransaction, supportsTransactions
close
boolean canAssignDemographicEnablers()
PERMISSION_DENIED.
This is intended as
a hint to an application that may opt not to offer lookup operations
to unauthorized users. false
if mapping is not authorized, true
otherwisemandatory
- This method must be implemented. boolean canAssignDemographicEnablersToBin(Id binId)
PERMISSION_DENIED.
This is intended as
a hint to an application that may opt not to offer lookup operations
to unauthorized users.binId
- the Id
of the Bin
false
if mapping is not authorized, true
otherwiseNullArgumentException
- binId
is
null
mandatory
- This method must be implemented. IdList getAssignableBinIds(Id binId) throws OperationFailedException
binId
- the Id
of the Bin
Ids
NullArgumentException
- binId
is
null
OperationFailedException
- unable to complete requestmandatory
- This method must be implemented. IdList getAssignableBinIdsForDemographicEnabler(Id binId, Id demographicEnablerId) throws OperationFailedException
binId
- the Id
of the Bin
demographicEnablerId
- the Id
of the
DemographicEnabler
Ids
NullArgumentException
- binId
or
demographicEnablerId
is null
OperationFailedException
- unable to complete requestmandatory
- This method must be implemented. void assignDemographicEnablerToBin(Id demographicEnablerId, Id binId) throws NotFoundException, OperationFailedException, PermissionDeniedException
DemographicEnabler
to an Bin.
demographicEnablerId
- the Id
of the
DemographicEnabler
binId
- the Id
of the Bin
NotFoundException
- demographicEnablerId
or binId
not foundNullArgumentException
- demographicEnablerId
or binId
is null
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. void unassignDemographicEnablerFromBin(Id demographicEnablerId, Id binId) throws NotFoundException, OperationFailedException, PermissionDeniedException
DemographicEnabler
from an Bin.
demographicEnablerId
- the Id
of the
DemographicEnabler
binId
- the Id
of the Bin
NotFoundException
- demographicEnablerId
or binId
not foundNullArgumentException
- demographicEnablerId
or binId
is null
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented.