Updated REAMDE to new constructs. Added Time repalcement Added ability

inactivate a device.
This commit is contained in:
Admin
2017-01-26 16:46:17 -06:00
parent 4b7ba0fabe
commit 611cc7be4a
15 changed files with 241 additions and 107 deletions

View File

@@ -74,6 +74,15 @@ public class DeviceRepository extends BackupHandler {
return list;
}
public List<DeviceDescriptor> findActive() {
List<DeviceDescriptor> list = new ArrayList<DeviceDescriptor>();
for(DeviceDescriptor aDevice : new ArrayList<DeviceDescriptor>(devices.values())) {
if(aDevice.getInactive() == null || !aDevice.getInactive())
list.add(aDevice);
}
return list;
}
public DeviceDescriptor findOne(String id) {
return devices.get(id);
}