public class CliRepository extends Object implements TelldusRepository
Constructor and Description |
---|
CliRepository(String tdtool) |
Modifier and Type | Method and Description |
---|---|
State |
dimDevice(int id,
int level) |
List<Device> |
getDevices() |
State |
getDeviceState(int id) |
List<Sensor> |
getSensors() |
State |
turnDeviceOff(int id) |
State |
turnDeviceOn(int id) |
public CliRepository(String tdtool)
public List<Device> getDevices()
getDevices
in interface TelldusRepository
Device
objects.public List<Sensor> getSensors() throws TelldusException
getSensors
in interface TelldusRepository
Sensor
objects.TelldusException
- if tdtool-command fails fatally.public State getDeviceState(int id) throws TelldusException
getDeviceState
in interface TelldusRepository
id
- the device id.State
object containing the device type and state.TelldusException
- if tdtool-command fails fatally.public State turnDeviceOn(int id) throws TelldusException
turnDeviceOn
in interface TelldusRepository
id
- the device id.TelldusException
- if tdtool-command fails fatally.public State turnDeviceOff(int id)
turnDeviceOff
in interface TelldusRepository
id
- the device id.TelldusException
- if tdtool-command fails fatally.public State dimDevice(int id, int level) throws TelldusException
dimDevice
in interface TelldusRepository
id
- the device id.level
- the dim-level value (0-255).TelldusException
- if tdtool-command fails fatally.Copyright © 2015. All rights reserved.