|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectjava.util.EventObject
cat.sensor.event.SensorEvent
cat.sensor.event.SensorDataEvent
This data event carries the sensor data that a sensor gets. For example, for a temperature sensor this event would contain the recorded temperature by the sensor.
Field Summary | |
private int |
type
The sensor type of the sensor that made this data. |
private Value |
value
The data value of the sensor. |
Fields inherited from class java.util.EventObject |
source |
Constructor Summary | |
SensorDataEvent(java.lang.String id,
int t,
Value v)
This constructor sets the id of the sensor sending the data event, and the data/value that the sensor is transmitting. |
|
SensorDataEvent(java.lang.String id,
Value v)
This constructor sets the id of the sensor sending the data event, and the data/value that the sensor is transmitting. |
Method Summary | |
Agent |
getAgent()
This returns the agent who owns the sensor. |
int |
getType()
This returns the type of the sensor that published this event. |
Value |
getValue()
This returns the value/data of the sensor that published this event. |
boolean |
isRemote()
This returns true if the sensor value/data is remote. |
Methods inherited from class java.util.EventObject |
getSource, toString |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
private Value value
private int type
Constructor Detail |
public SensorDataEvent(java.lang.String id, Value v)
id
- The unique id of the sensor sending the data event.v
- The value/data of the sensor.public SensorDataEvent(java.lang.String id, int t, Value v)
id
- The unique id of the sensor sending the data event.v
- The value/data of the sensor.t
- The type of the sensor.Method Detail |
public int getType()
public Value getValue()
public boolean isRemote()
public Agent getAgent()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |