23 port.setInputMode(
true);
24 port.setOutputMode(
false);
25 port.setRpcMode(
true);
37 yCError(RPCSERVER,
"%s cannot write, please use a regular Port or RpcClient for that", port.getName().c_str());
48 yCError(RPCSERVER,
"%s cannot write, please use a regular Port or RpcClient for that", port.getName().c_str());
55 yCError(RPCSERVER,
"%s must reply, please use a regular Port if you do not want to", port.getName().c_str());
59 return port.read(reader,
true);
Interface implemented by all objects that can read themselves from the network, such as Bottle object...
Interface implemented by all objects that can write themselves to the network, such as Bottle objects...
bool read(PortReader &reader, bool willReply=true) override
Read an object from the port.
virtual ~RpcServer()
Destructor.
void setInputMode(bool expectInput) override
Configure the port to allow or forbid inputs.
virtual bool write(const PortWriter &writer, const PortWriter *callback=nullptr) const override
Write cannot be called by RPCServer.
void setOutputMode(bool expectOutput) override
Configure the port to allow or forbid outputs.
void setRpcMode(bool expectRpc) override
Configure the port to be RPC only.
#define yCError(component,...)
#define yCAssert(component, x)
#define YARP_OS_LOG_COMPONENT(name, name_string)
The components from which ports and connections are built.
An interface to the operating system, including Port based communication.