Package org.hypermedea.ros
Class ROSOperation
java.lang.Object
org.hypermedea.op.BaseOperation
org.hypermedea.ros.ROSOperation
- All Implemented Interfaces:
org.hypermedea.op.Operation
- Direct Known Subclasses:
ROSCancelOperation,ROSGetStatusOperation,ROSPublishOperation,ROSSendGoalOperation,ROSSubscribeOperation
public abstract class ROSOperation
extends org.hypermedea.op.BaseOperation
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final Stringprotected final edu.wpi.rail.jrosbridge.TopicFields inherited from class org.hypermedea.op.BaseOperation
DEFAULT_TIMEOUT, form, operationStarted, payload, targetFields inherited from interface org.hypermedea.op.Operation
DELETE, GET, METHOD_NAME_FIELD, PATCH, POST, PUT, WATCH -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected javax.json.JsonStructureprotected StringReturn the operation-specific default message type.protected abstract StringgetTopicName(String path) Map the path element of the operation's target URI to a ROS topic.protected ObjectparseJson(javax.json.JsonStructure json) protected NumberparseJsonNumber(javax.json.JsonNumber nb) protected voidMethods inherited from class org.hypermedea.op.BaseOperation
end, getForm, getMethod, getPayload, getResponse, getTargetURI, isAsync, isIdempotent, isSafe, onError, onResponse, registerResponseCallback, sendRequest, setPayload, setPayload, setTimeout, toString, unregisterResponseCallback
-
Field Details
-
DEFAULT_MESSAGE_TYPE
- See Also:
-
topic
protected final edu.wpi.rail.jrosbridge.Topic topic
-
-
Constructor Details
-
ROSOperation
-
-
Method Details
-
sendSingleRequest
- Specified by:
sendSingleRequestin classorg.hypermedea.op.BaseOperation- Throws:
IOException
-
getTopicName
Map the path element of the operation's target URI to a ROS topic.- Parameters:
path- path of the target URI declared in the input form- Returns:
- a full topic name for the operation
-
getDefaultMessageType
Return the operation-specific default message type.- Returns:
- a message type, e.g. "std_msgs/String"
-
parseJson
-
parseJsonNumber
-
buildJson
-