public interface RegionStore extends Store<RegionEvent,RegionStoreDelegate>
| Modifier and Type | Method and Description | 
|---|---|
void | 
addDevices(RegionId regionId,
          Collection<DeviceId> deviceIds)
Adds the specified collection of devices to the region. 
 | 
Region | 
createRegion(RegionId regionId,
            String name,
            Region.Type type,
            Annotations annots,
            List<Set<NodeId>> masterNodeIds)
Creates a new region using the supplied data. 
 | 
Region | 
getRegion(RegionId regionId)
Returns the region with the specified identifier. 
 | 
Set<DeviceId> | 
getRegionDevices(RegionId regionId)
Returns the set of devices that belong to the specified region. 
 | 
Region | 
getRegionForDevice(DeviceId deviceId)
Returns the region to which the specified device belongs. 
 | 
Set<Region> | 
getRegions()
Returns set of all regions. 
 | 
void | 
removeDevices(RegionId regionId,
             Collection<DeviceId> deviceIds)
Removes the specified collection of devices from the region. 
 | 
void | 
removeRegion(RegionId regionId)
Removes the specified region using the new set of data. 
 | 
Region | 
updateRegion(RegionId regionId,
            String name,
            Region.Type type,
            Annotations annots,
            List<Set<NodeId>> masterNodeIds)
Updates the specified new region using the supplied data. 
 | 
hasDelegate, setDelegate, unsetDelegateRegion getRegion(RegionId regionId)
regionId - region identifierItemNotFoundException - if region with given
                                              id does not existRegion getRegionForDevice(DeviceId deviceId)
deviceId - device identifierSet<DeviceId> getRegionDevices(RegionId regionId)
regionId - region identifierRegion createRegion(RegionId regionId, String name, Region.Type type, Annotations annots, List<Set<NodeId>> masterNodeIds)
regionId - region identifiername - friendly nametype - region typeannots - annotationsmasterNodeIds - list of master nodes; null implies empty listIllegalArgumentException - if item already existsRegion updateRegion(RegionId regionId, String name, Region.Type type, Annotations annots, List<Set<NodeId>> masterNodeIds)
regionId - region identifiername - friendly nametype - region typeannots - annotationsmasterNodeIds - list of master nodes; null implies empty listIllegalArgumentException - if item already existsvoid removeRegion(RegionId regionId)
regionId - region identifiervoid addDevices(RegionId regionId, Collection<DeviceId> deviceIds)
regionId - region identifierdeviceIds - list of device identifiersvoid removeDevices(RegionId regionId, Collection<DeviceId> deviceIds)
regionId - region identifierdeviceIds - list of device identifiers