Interface DeviceEnablerRuleApplicationSession
- All Superinterfaces:
AutoCloseable, Closeable, OsidSession, OsidSession
This session provides methods to apply DeviceEnablers to
Devices . A Device with multiple DeviceEnablers means any
positive rule evaluation across the enablers result in an active
Device .
-
Method Summary
Modifier and TypeMethodDescriptionvoidassignDeviceEnablerToDevice(Id deviceEnablerId, Id deviceId) Adds an existingDeviceEnablerto aDevice.booleanTests if this user can alter device enabler/device mappings.booleanTests if this user can orderDeviceEnablers.Gets theSystemassociated with this session.Gets theSystemIdassociated with this session.voidmoveDeviceEnablerAhead(Id deviceEnablerId, Id deviceId, Id referenceId) Reorders device enablers for a device by moving the specified device enabler in front of a reference device enabler.voidmoveDeviceEnablerBehind(Id deviceEnablerId, Id deviceId, Id referenceId) Reorders device enablers for a device by moving the specified device enabler behind a reference device enabler.voidorderDeviceEnablers(Id[] deviceEnablerIds, Id deviceId) Reorders a set of device enablers for a device.voidunassignDeviceEnablerFromDevice(Id deviceEnablerId, Id deviceId) Removes aDeviceEnablerfrom aDevice.Methods inherited from interface OsidSession
closeMethods inherited from interface OsidSession
getAuthenticatedAgent, getAuthenticatedAgentId, getClockRate, getDate, getEffectiveAgent, getEffectiveAgentId, getFormatType, getLocale, isAuthenticated, startTransaction, supportsTransactionsModifier and TypeMethodDescriptionGets the agent authenticated to this session.Gets theIdof the agent authenticated to this session.Gets the rate of the service clock.getDate()Gets the service date which may be the current date or the effective date in which this session exists.Gets the effective agent in use by this session.Gets theIdof the effective agent in use by this session.Gets theDisplayTextformatTypepreference in effect for this session.Gets the locale indicating the localization preferences in effect for this session.booleanTests if an agent is authenticated to this session.Starts a new transaction for this sesson.booleanTests for the availability of transactions.
-
Method Details
-
getSystemId
Id getSystemId()Gets theSystemIdassociated with this session.- Returns:
- the
System Idassociated with this session - Compliance:
mandatory- This method must be implemented.
-
getSystem
Gets theSystemassociated with this session.- Returns:
- the system
- Throws:
OperationFailedException- unable to complete requestPermissionDeniedException- authorization failure- Compliance:
mandatory- This method must be implemented.
-
canAssignDeviceEnablers
boolean canAssignDeviceEnablers()Tests if this user can alter device enabler/device mappings. A return of true does not guarantee successful authorization. A return of false indicates that it is known mapping methods in this session will result in aPERMISSION_DENIED. This is intended as a hint to an application that may opt not to offer lookup operations to unauthorized users.- Returns:
falseif mapping is not authorized,trueotherwise- Compliance:
mandatory- This method must be implemented.
-
assignDeviceEnablerToDevice
void assignDeviceEnablerToDevice(Id deviceEnablerId, Id deviceId) throws AlreadyExistsException, NotFoundException, OperationFailedException, PermissionDeniedException Adds an existingDeviceEnablerto aDevice.- Parameters:
deviceEnablerId- theIdof theDeviceEnablerdeviceId- theIdof theDevice- Throws:
AlreadyExistsException-deviceEnablerIdalready applied todeviceIdNotFoundException-deviceEnablerIdordeviceIdnot foundNullArgumentException-deviceEnablerIdordeviceIdisnullOperationFailedException- unable to complete requestPermissionDeniedException- authorization failure- Compliance:
mandatory- This method must be implemented.
-
unassignDeviceEnablerFromDevice
void unassignDeviceEnablerFromDevice(Id deviceEnablerId, Id deviceId) throws NotFoundException, OperationFailedException, PermissionDeniedException Removes aDeviceEnablerfrom aDevice.- Parameters:
deviceEnablerId- theIdof theDeviceEnablerdeviceId- theIdof theDevice- Throws:
NotFoundException-deviceEnablerIdordeviceIdnot found ordeviceEnablerIdnot applied todeviceIdNullArgumentException-deviceEnablerIdordeviceIdisnullOperationFailedException- unable to complete requestPermissionDeniedException- authorization failure- Compliance:
mandatory- This method must be implemented.
-
canSequenceDeviceEnablers
boolean canSequenceDeviceEnablers()Tests if this user can orderDeviceEnablers. A return of true does not guarantee successful authorization. A return of false indicates that it is known sequencing operations will result in aPERMISSION_DENIED. This is intended as a hint to an application that may opt not to offer sequencing operations to an unauthorized user.- Returns:
falseifDeviceEnablerordering is not authorized,trueotherwise- Compliance:
mandatory- This method must be implemented.
-
moveDeviceEnablerAhead
void moveDeviceEnablerAhead(Id deviceEnablerId, Id deviceId, Id referenceId) throws NotFoundException, OperationFailedException, PermissionDeniedException Reorders device enablers for a device by moving the specified device enabler in front of a reference device enabler.- Parameters:
deviceEnablerId- theIdof aDeviceEnablerdeviceId- theIdof aDevicereferenceId- the reference device enablerId- Throws:
NotFoundException-deviceEnablerId, deviceId, orreferenceIdnot found or,deviceEnablerIdorreferenceIdnot related todeviceIdNullArgumentException-deviceEnablerId, deviceId, orreferenceIdisnullOperationFailedException- unable to complete requestPermissionDeniedException- authorization failure- Compliance:
mandatory- This method must be implemented.
-
moveDeviceEnablerBehind
void moveDeviceEnablerBehind(Id deviceEnablerId, Id deviceId, Id referenceId) throws NotFoundException, OperationFailedException, PermissionDeniedException Reorders device enablers for a device by moving the specified device enabler behind a reference device enabler.- Parameters:
deviceEnablerId- theIdof aDeviceEnablerdeviceId- theIdof aDevicereferenceId- the reference device enablerId- Throws:
NotFoundException-deviceEnablerId, deviceId, orreferenceIdnot found or,deviceEnablerIdorreferenceIdnot related todeviceIdNullArgumentException-deviceEnablerId, deviceId, orreferenceIdisnullOperationFailedException- unable to complete requestPermissionDeniedException- authorization failure- Compliance:
mandatory- This method must be implemented.
-
orderDeviceEnablers
void orderDeviceEnablers(Id[] deviceEnablerIds, Id deviceId) throws NotFoundException, OperationFailedException, PermissionDeniedException Reorders a set of device enablers for a device.- Parameters:
deviceEnablerIds- theIdsfor a set ofDeviceEnablersdeviceId- theIdof aDevice- Throws:
NotFoundException-deviceConstraienrIdnot found or, adeviceEnablerIdnot related todeviceIdNullArgumentException-deviceEnablerIdsordeviceIdisnullOperationFailedException- unable to complete requestPermissionDeniedException- authorization failure- Compliance:
mandatory- This method must be implemented.
-