UNPKG

@foxglove/ros1

Version:

Standalone TypeScript implementation of the ROS 1 (Robot Operating System) protocol with a pluggable transport layer

46 lines 1.83 kB
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.RosParamClient = void 0; const RosXmlRpcClient_1 = require("./RosXmlRpcClient"); class RosParamClient extends RosXmlRpcClient_1.RosXmlRpcClient { async deleteParam(callerId, key) { return await this._methodCall("deleteParam", [callerId, key]); } async setParam(callerId, key, value) { return await this._methodCall("setParam", [callerId, key, value]); } async getParam(callerId, key) { return await this._methodCall("getParam", [callerId, key]); } async searchParam(callerId, key) { return await this._methodCall("searchParam", [callerId, key]); } async subscribeParam(callerId, callerApi, key) { return await this._methodCall("subscribeParam", [callerId, callerApi, key]); } async subscribeParams(callerId, callerApi, keys) { const requests = keys.map((key) => ({ methodName: "subscribeParam", params: [callerId, callerApi, key], })); return await this._multiMethodCall(requests); } async unsubscribeParam(callerId, callerApi, key) { return await this._methodCall("unsubscribeParam", [callerId, callerApi, key]); } async unsubscribeParams(callerId, callerApi, keys) { const requests = keys.map((key) => ({ methodName: "unsubscribeParam", params: [callerId, callerApi, key], })); return await this._multiMethodCall(requests); } async hasParam(callerId, key) { return await this._methodCall("hasParam", [callerId, key]); } async getParamNames(callerId) { return await this._methodCall("getParamNames", [callerId]); } } exports.RosParamClient = RosParamClient; //# sourceMappingURL=RosParamClient.js.map