public class DweetSink extends ContextualVehicleDataSink
Modifier and Type | Field and Description |
---|---|
android.content.Context |
mContext |
java.lang.String |
mThingName |
Constructor and Description |
---|
DweetSink(android.content.Context context,
java.lang.String thing_name)
Initialize and start a new DweetSink immediately.
|
Modifier and Type | Method and Description |
---|---|
void |
receive(VehicleMessage message)
Receive a data point with a name, a value and a event value.
|
void |
stop()
Release any acquired resources and either stop sending measurements (if a
source) or stop expecting to receive them (if a sink).
|
getContext
public java.lang.String mThingName
public android.content.Context mContext
public DweetSink(android.content.Context context, java.lang.String thing_name)
thing_name
- the Thing Name to send Dweets to with the JSON data.public void stop()
VehicleDataSink
stop
in interface VehicleDataSink
stop
in class ContextualVehicleDataSink
public void receive(VehicleMessage message)
VehicleDataSink
receive
in interface VehicleDataSink
receive
in class ContextualVehicleDataSink
message
- The new measurement.