public interface IDeviceManagement extends ITenantLifecycleComponent
Modifier and Type | Method and Description |
---|---|
java.util.List<IDeviceGroupElement> |
addDeviceGroupElements(java.lang.String groupToken,
java.util.List<IDeviceGroupElementCreateRequest> elements,
boolean ignoreDuplicates)
Add elements to a device group.
|
IBatchOperation |
createBatchCommandInvocation(IBatchCommandInvocationRequest request)
Creates an
ISearchResults that will invoke a command on multiple
devices. |
IBatchOperation |
createBatchOperation(IBatchOperationCreateRequest request)
Creates an
IBatchOperation to perform an operation on multiple
devices. |
IDevice |
createDevice(IDeviceCreateRequest device)
Create a new device.
|
IDeviceAssignment |
createDeviceAssignment(IDeviceAssignmentCreateRequest request)
Create a new device assignment.
|
IDeviceCommand |
createDeviceCommand(IDeviceSpecification spec,
IDeviceCommandCreateRequest request)
Creates a device command associated with an existing device
specification.
|
IDevice |
createDeviceElementMapping(java.lang.String hardwareId,
IDeviceElementMapping mapping)
Create an
IDeviceElementMapping for a nested device. |
IDeviceGroup |
createDeviceGroup(IDeviceGroupCreateRequest request)
Create a new device group.
|
IDeviceSpecification |
createDeviceSpecification(IDeviceSpecificationCreateRequest request)
Create a new device specification.
|
IDeviceStream |
createDeviceStream(java.lang.String assignmentToken,
IDeviceStreamCreateRequest request)
Create a new
IDeviceStream associated with an assignment. |
ISite |
createSite(ISiteCreateRequest request)
Create a site based on the given input.
|
IZone |
createZone(ISite site,
IZoneCreateRequest request)
Create a new zone.
|
IBatchOperation |
deleteBatchOperation(java.lang.String token,
boolean force)
Deletes a batch operation and its elements.
|
IDevice |
deleteDevice(java.lang.String hardwareId,
boolean force)
Delete an existing device.
|
IDeviceAssignment |
deleteDeviceAssignment(java.lang.String token,
boolean force)
Delete a device assignment.
|
IDeviceCommand |
deleteDeviceCommand(java.lang.String token,
boolean force)
Delete an existing device command.
|
IDevice |
deleteDeviceElementMapping(java.lang.String hardwareId,
java.lang.String path)
Delete an exising
IDeviceElementMapping from a device. |
IDeviceGroup |
deleteDeviceGroup(java.lang.String token,
boolean force)
Delete a device group.
|
IDeviceSpecification |
deleteDeviceSpecification(java.lang.String token,
boolean force)
Delete an existing device specification.
|
ISite |
deleteSite(java.lang.String siteToken,
boolean force)
Delete a site based on unique site token.
|
IZone |
deleteZone(java.lang.String zoneToken,
boolean force)
Delete a zone given its unique token.
|
IDeviceAssignment |
endDeviceAssignment(java.lang.String token)
Ends a device assignment.
|
IBatchOperation |
getBatchOperation(java.lang.String token)
Get an
IBatchOperation by unique token. |
IDeviceAssignment |
getCurrentDeviceAssignment(IDevice device)
Gets the current assignment for a device.
|
IDeviceAssignment |
getDeviceAssignmentByToken(java.lang.String token)
Get a device assignment by unique token.
|
ISearchResults<IDeviceAssignment> |
getDeviceAssignmentHistory(java.lang.String hardwareId,
ISearchCriteria criteria)
Get the device assignment history for a given device.
|
ISearchResults<IDeviceAssignment> |
getDeviceAssignmentsForAsset(java.lang.String assetModuleId,
java.lang.String assetId,
IAssignmentsForAssetSearchCriteria criteria)
Get a list of device assignments associated with a given asset.
|
ISearchResults<IDeviceAssignment> |
getDeviceAssignmentsForSite(java.lang.String siteToken,
IAssignmentSearchCriteria criteria)
Get a list of device assignments for a site.
|
ISearchResults<IDeviceAssignment> |
getDeviceAssignmentsWithLastInteraction(java.lang.String siteToken,
IDateRangeSearchCriteria criteria)
Finds all device assignments for a site with a last interaction date in
the given date range.
|
IDevice |
getDeviceByHardwareId(java.lang.String hardwareId)
Gets a device by unique hardware id.
|
IDeviceCommand |
getDeviceCommandByToken(java.lang.String token)
Get a device command by unique token.
|
IDevice |
getDeviceForAssignment(IDeviceAssignment assignment)
Get the device associated with an assignment.
|
IDeviceGroup |
getDeviceGroup(java.lang.String token)
Get a device network by unique token.
|
IDeviceSpecification |
getDeviceSpecificationByToken(java.lang.String token)
Get a device specification by unique token.
|
IDeviceStream |
getDeviceStream(java.lang.String assignmentToken,
java.lang.String streamId)
Get an exsiting
IDeviceStream for an assignment based on unique
stream id. |
ISearchResults<IDeviceAssignment> |
getMissingDeviceAssignments(java.lang.String siteToken,
ISearchCriteria criteria)
Find all device assignments that have been marked missing by the presence
manager.
|
ISite |
getSiteByToken(java.lang.String token)
Get a site by unique token.
|
ISite |
getSiteForAssignment(IDeviceAssignment assignment)
Get the site associated with an assignment.
|
IZone |
getZone(java.lang.String zoneToken)
Get a zone by its unique token.
|
ISearchResults<IBatchElement> |
listBatchElements(java.lang.String batchToken,
IBatchElementSearchCriteria criteria)
Lists elements for an
IBatchOperation that meet the given
criteria. |
ISearchResults<IBatchOperation> |
listBatchOperations(boolean includeDeleted,
ISearchCriteria criteria)
List batch operations based on the given criteria.
|
java.util.List<IDeviceCommand> |
listDeviceCommands(java.lang.String specToken,
boolean includeDeleted)
List device command objects associated with a device specification.
|
ISearchResults<IDeviceGroupElement> |
listDeviceGroupElements(java.lang.String groupToken,
ISearchCriteria criteria)
List device group elements that meet the given criteria.
|
ISearchResults<IDeviceGroup> |
listDeviceGroups(boolean includeDeleted,
ISearchCriteria criteria)
List device groups.
|
ISearchResults<IDeviceGroup> |
listDeviceGroupsWithRole(java.lang.String role,
boolean includeDeleted,
ISearchCriteria criteria)
Lists all device groups that have the given role.
|
ISearchResults<IDevice> |
listDevices(boolean includeDeleted,
IDeviceSearchCriteria criteria)
List devices that meet the given criteria.
|
ISearchResults<IDeviceSpecification> |
listDeviceSpecifications(boolean includeDeleted,
ISearchCriteria criteria)
List device specifications that match the search criteria.
|
ISearchResults<IDeviceStream> |
listDeviceStreams(java.lang.String assignmentToken,
ISearchCriteria criteria)
List device streams for the assignment that meet the given criteria.
|
ISearchResults<ISite> |
listSites(ISearchCriteria criteria)
Get a list of all sites.
|
ISearchResults<IZone> |
listZones(java.lang.String siteToken,
ISearchCriteria criteria)
Get a list of all zones associated with a Site.
|
java.util.List<IDeviceGroupElement> |
removeDeviceGroupElements(java.lang.String groupToken,
java.util.List<IDeviceGroupElementCreateRequest> elements)
Remove selected elements from a device group.
|
IBatchElement |
updateBatchElement(java.lang.String operationToken,
long index,
IBatchElementUpdateRequest request)
Updates an existing batch operation element.
|
IBatchOperation |
updateBatchOperation(java.lang.String token,
IBatchOperationUpdateRequest request)
Update an existing
IBatchOperation . |
IDevice |
updateDevice(java.lang.String hardwareId,
IDeviceCreateRequest request)
Update device information.
|
IDeviceAssignment |
updateDeviceAssignmentMetadata(java.lang.String token,
IMetadataProvider metadata)
Update metadata associated with a device assignment.
|
IDeviceAssignment |
updateDeviceAssignmentState(java.lang.String token,
IDeviceAssignmentState state)
Updates the current state of a device assignment.
|
IDeviceAssignment |
updateDeviceAssignmentStatus(java.lang.String token,
DeviceAssignmentStatus status)
Update the status of an existing device assignment.
|
IDeviceCommand |
updateDeviceCommand(java.lang.String token,
IDeviceCommandCreateRequest request)
Update an existing device command.
|
IDeviceGroup |
updateDeviceGroup(java.lang.String token,
IDeviceGroupCreateRequest request)
Update an existing device group.
|
IDeviceSpecification |
updateDeviceSpecification(java.lang.String token,
IDeviceSpecificationCreateRequest request)
Update an existing device specification.
|
ISite |
updateSite(java.lang.String siteToken,
ISiteCreateRequest request)
Update information for a site.
|
IZone |
updateZone(java.lang.String token,
IZoneCreateRequest request)
Update an existing zone.
|
getTenant, setTenant
canPause, findComponentsOfType, getComponentId, getComponentName, getComponentType, getCreatedDate, getLifecycleComponents, getLifecycleError, getLifecycleStatus, getLogger, initialize, initializeNestedComponent, lifecycleInitialize, lifecyclePause, lifecycleStart, lifecycleStop, lifecycleStop, logState, pause, start, startNestedComponent, stop, stop
IDeviceSpecification createDeviceSpecification(IDeviceSpecificationCreateRequest request) throws SiteWhereException
request
- information about new specificationSiteWhereException
IDeviceSpecification getDeviceSpecificationByToken(java.lang.String token) throws SiteWhereException
token
- unique device specification tokenSiteWhereException
- if implementation encountered an errorIDeviceSpecification updateDeviceSpecification(java.lang.String token, IDeviceSpecificationCreateRequest request) throws SiteWhereException
token
- unique specification tokenrequest
- updated informationSiteWhereException
- if implementation encountered an errorISearchResults<IDeviceSpecification> listDeviceSpecifications(boolean includeDeleted, ISearchCriteria criteria) throws SiteWhereException
includeDeleted
- include specifications marked as deletedcriteria
- search criteriaSiteWhereException
- if implementation encountered an errorIDeviceSpecification deleteDeviceSpecification(java.lang.String token, boolean force) throws SiteWhereException
token
- unique specification tokenforce
- if true, deletes specification. if false, marks as deleted.SiteWhereException
- if implementation encountered an errorIDeviceCommand createDeviceCommand(IDeviceSpecification spec, IDeviceCommandCreateRequest request) throws SiteWhereException
spec
- request
- SiteWhereException
IDeviceCommand getDeviceCommandByToken(java.lang.String token) throws SiteWhereException
token
- SiteWhereException
IDeviceCommand updateDeviceCommand(java.lang.String token, IDeviceCommandCreateRequest request) throws SiteWhereException
token
- request
- SiteWhereException
java.util.List<IDeviceCommand> listDeviceCommands(java.lang.String specToken, boolean includeDeleted) throws SiteWhereException
specToken
- includeDeleted
- SiteWhereException
IDeviceCommand deleteDeviceCommand(java.lang.String token, boolean force) throws SiteWhereException
token
- force
- SiteWhereException
IDevice createDevice(IDeviceCreateRequest device) throws SiteWhereException
device
- SiteWhereException
IDevice getDeviceByHardwareId(java.lang.String hardwareId) throws SiteWhereException
hardwareId
- SiteWhereException
IDevice updateDevice(java.lang.String hardwareId, IDeviceCreateRequest request) throws SiteWhereException
hardwareId
- request
- SiteWhereException
IDeviceAssignment getCurrentDeviceAssignment(IDevice device) throws SiteWhereException
device
- SiteWhereException
ISearchResults<IDevice> listDevices(boolean includeDeleted, IDeviceSearchCriteria criteria) throws SiteWhereException
includeDeleted
- criteria
- SiteWhereException
IDevice createDeviceElementMapping(java.lang.String hardwareId, IDeviceElementMapping mapping) throws SiteWhereException
IDeviceElementMapping
for a nested device.hardwareId
- mapping
- SiteWhereException
IDevice deleteDeviceElementMapping(java.lang.String hardwareId, java.lang.String path) throws SiteWhereException
IDeviceElementMapping
from a device.hardwareId
- path
- SiteWhereException
IDevice deleteDevice(java.lang.String hardwareId, boolean force) throws SiteWhereException
hardwareId
- force
- SiteWhereException
IDeviceAssignment createDeviceAssignment(IDeviceAssignmentCreateRequest request) throws SiteWhereException
request
- SiteWhereException
IDeviceAssignment getDeviceAssignmentByToken(java.lang.String token) throws SiteWhereException
token
- SiteWhereException
IDeviceAssignment deleteDeviceAssignment(java.lang.String token, boolean force) throws SiteWhereException
token
- force
- SiteWhereException
IDevice getDeviceForAssignment(IDeviceAssignment assignment) throws SiteWhereException
assignment
- SiteWhereException
ISite getSiteForAssignment(IDeviceAssignment assignment) throws SiteWhereException
assignment
- SiteWhereException
IDeviceAssignment updateDeviceAssignmentMetadata(java.lang.String token, IMetadataProvider metadata) throws SiteWhereException
token
- metadata
- SiteWhereException
IDeviceAssignment updateDeviceAssignmentStatus(java.lang.String token, DeviceAssignmentStatus status) throws SiteWhereException
token
- status
- SiteWhereException
IDeviceAssignment updateDeviceAssignmentState(java.lang.String token, IDeviceAssignmentState state) throws SiteWhereException
token
- state
- SiteWhereException
IDeviceAssignment endDeviceAssignment(java.lang.String token) throws SiteWhereException
token
- SiteWhereException
ISearchResults<IDeviceAssignment> getDeviceAssignmentHistory(java.lang.String hardwareId, ISearchCriteria criteria) throws SiteWhereException
hardwareId
- criteria
- SiteWhereException
ISearchResults<IDeviceAssignment> getDeviceAssignmentsForSite(java.lang.String siteToken, IAssignmentSearchCriteria criteria) throws SiteWhereException
siteToken
- criteria
- SiteWhereException
ISearchResults<IDeviceAssignment> getDeviceAssignmentsWithLastInteraction(java.lang.String siteToken, IDateRangeSearchCriteria criteria) throws SiteWhereException
siteToken
- criteria
- SiteWhereException
ISearchResults<IDeviceAssignment> getMissingDeviceAssignments(java.lang.String siteToken, ISearchCriteria criteria) throws SiteWhereException
siteToken
- criteria
- SiteWhereException
ISearchResults<IDeviceAssignment> getDeviceAssignmentsForAsset(java.lang.String assetModuleId, java.lang.String assetId, IAssignmentsForAssetSearchCriteria criteria) throws SiteWhereException
assetModuleId
- assetId
- criteria
- SiteWhereException
IDeviceStream createDeviceStream(java.lang.String assignmentToken, IDeviceStreamCreateRequest request) throws SiteWhereException
IDeviceStream
associated with an assignment.assignmentToken
- request
- SiteWhereException
IDeviceStream getDeviceStream(java.lang.String assignmentToken, java.lang.String streamId) throws SiteWhereException
IDeviceStream
for an assignment based on unique
stream id. Returns null if not found.assignmentToken
- streamId
- SiteWhereException
ISearchResults<IDeviceStream> listDeviceStreams(java.lang.String assignmentToken, ISearchCriteria criteria) throws SiteWhereException
assignmentToken
- criteria
- SiteWhereException
ISite createSite(ISiteCreateRequest request) throws SiteWhereException
request
- SiteWhereException
ISite deleteSite(java.lang.String siteToken, boolean force) throws SiteWhereException
siteToken
- force
- SiteWhereException
ISite updateSite(java.lang.String siteToken, ISiteCreateRequest request) throws SiteWhereException
siteToken
- request
- SiteWhereException
ISite getSiteByToken(java.lang.String token) throws SiteWhereException
token
- SiteWhereException
ISearchResults<ISite> listSites(ISearchCriteria criteria) throws SiteWhereException
criteria
- SiteWhereException
IZone createZone(ISite site, IZoneCreateRequest request) throws SiteWhereException
site
- request
- SiteWhereException
IZone updateZone(java.lang.String token, IZoneCreateRequest request) throws SiteWhereException
token
- request
- SiteWhereException
IZone getZone(java.lang.String zoneToken) throws SiteWhereException
zoneToken
- SiteWhereException
ISearchResults<IZone> listZones(java.lang.String siteToken, ISearchCriteria criteria) throws SiteWhereException
siteToken
- criteria
- SiteWhereException
IZone deleteZone(java.lang.String zoneToken, boolean force) throws SiteWhereException
zoneToken
- force
- SiteWhereException
IDeviceGroup createDeviceGroup(IDeviceGroupCreateRequest request) throws SiteWhereException
request
- SiteWhereException
IDeviceGroup updateDeviceGroup(java.lang.String token, IDeviceGroupCreateRequest request) throws SiteWhereException
token
- request
- SiteWhereException
IDeviceGroup getDeviceGroup(java.lang.String token) throws SiteWhereException
token
- SiteWhereException
ISearchResults<IDeviceGroup> listDeviceGroups(boolean includeDeleted, ISearchCriteria criteria) throws SiteWhereException
includeDeleted
- criteria
- SiteWhereException
ISearchResults<IDeviceGroup> listDeviceGroupsWithRole(java.lang.String role, boolean includeDeleted, ISearchCriteria criteria) throws SiteWhereException
role
- includeDeleted
- criteria
- SiteWhereException
IDeviceGroup deleteDeviceGroup(java.lang.String token, boolean force) throws SiteWhereException
token
- force
- SiteWhereException
java.util.List<IDeviceGroupElement> addDeviceGroupElements(java.lang.String groupToken, java.util.List<IDeviceGroupElementCreateRequest> elements, boolean ignoreDuplicates) throws SiteWhereException
groupToken
- elements
- ignoreDuplicates
- SiteWhereException
java.util.List<IDeviceGroupElement> removeDeviceGroupElements(java.lang.String groupToken, java.util.List<IDeviceGroupElementCreateRequest> elements) throws SiteWhereException
groupToken
- elements
- SiteWhereException
ISearchResults<IDeviceGroupElement> listDeviceGroupElements(java.lang.String groupToken, ISearchCriteria criteria) throws SiteWhereException
groupToken
- criteria
- SiteWhereException
IBatchOperation createBatchOperation(IBatchOperationCreateRequest request) throws SiteWhereException
IBatchOperation
to perform an operation on multiple
devices.request
- SiteWhereException
IBatchOperation updateBatchOperation(java.lang.String token, IBatchOperationUpdateRequest request) throws SiteWhereException
IBatchOperation
.token
- request
- SiteWhereException
IBatchOperation getBatchOperation(java.lang.String token) throws SiteWhereException
IBatchOperation
by unique token.token
- SiteWhereException
ISearchResults<IBatchOperation> listBatchOperations(boolean includeDeleted, ISearchCriteria criteria) throws SiteWhereException
includeDeleted
- criteria
- SiteWhereException
IBatchOperation deleteBatchOperation(java.lang.String token, boolean force) throws SiteWhereException
token
- force
- SiteWhereException
ISearchResults<IBatchElement> listBatchElements(java.lang.String batchToken, IBatchElementSearchCriteria criteria) throws SiteWhereException
IBatchOperation
that meet the given
criteria.batchToken
- criteria
- SiteWhereException
IBatchElement updateBatchElement(java.lang.String operationToken, long index, IBatchElementUpdateRequest request) throws SiteWhereException
operationToken
- index
- request
- SiteWhereException
IBatchOperation createBatchCommandInvocation(IBatchCommandInvocationRequest request) throws SiteWhereException
ISearchResults
that will invoke a command on multiple
devices.request
- SiteWhereException