public class BooleanBackend extends OnNewRosMessageSource implements Backend
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
MYTYPE |
Constructor and Description |
---|
BooleanBackend(java.lang.String topic,
java.lang.String type,
int[] dimensionSizes,
org.ros.node.ConnectedNode myRosNode,
boolean publish) |
Modifier and Type | Method and Description |
---|---|
void |
checkDimensionSizes(std_msgs.Bool mess)
just a single bool, not an array
|
float[] |
decodeMessage(org.ros.internal.message.Message mess)
Get message data (this receives arrays of floats, so just return the payload).
|
int |
gedNumOfDimensions()
The data from ROS message are concatenated into one vector
of float values.
|
void |
publish(float[] data)
This thing gets data of given format and publishes them as a ROS message
to a specified topic.
|
void |
setReceivedRosMessage(std_msgs.Bool mess) |
addEventListener, fireOnNewMessage, removeEventListener
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
addEventListener, fireOnNewMessage
removeEventListener
public static final java.lang.String MYTYPE
public BooleanBackend(java.lang.String topic, java.lang.String type, int[] dimensionSizes, org.ros.node.ConnectedNode myRosNode, boolean publish) throws MessageFormatException
MessageFormatException
public void publish(float[] data)
publish
in interface Backend
MessageFormatException
public void setReceivedRosMessage(std_msgs.Bool mess)
public void checkDimensionSizes(std_msgs.Bool mess)
mess
- public float[] decodeMessage(org.ros.internal.message.Message mess)
decodeMessage
in interface Backend
public int gedNumOfDimensions()
Backend
gedNumOfDimensions
in interface Backend