33 if(config.
check(
"default-client")) {
37 if(config.
check(
"default-server")) {
41 if (config.
check(
"nwc_thrift_port_prefix")){
42 prefix = config.
find(
"nwc_thrift_port_prefix").asString() + (
default_config ? m_defaultConfigPrefix :
"");
43 if(prefix[0] !=
'/') {prefix =
"/"+prefix;}
44 m_thriftPortName = prefix +
"/" + m_deviceName +
"/thrift";
48 m_thriftPortName = prefix +
"/" + m_deviceName +
"/thrift";
53 if (config.
check(
"nws_thrift_port_prefix")){
54 prefix = config.
find(
"nws_thrift_port_prefix").asString() + (
default_server ? m_defaultServerPrefix :
"");
55 if(prefix[0] !=
'/') {prefix =
"/"+prefix;}
56 m_thrift_server_rpcPort_Name = prefix +
"/thrift";
60 m_thrift_server_rpcPort_Name = prefix +
"/thrift";
65 if(!m_thriftPort.
open(m_thriftPortName))
96 std::lock_guard <std::mutex>
lg(m_pd_mutex);
109 std::lock_guard <std::mutex>
lg(m_pd_mutex);
122 std::lock_guard <std::mutex>
lg(m_pd_mutex);
135 std::lock_guard <std::mutex>
lg(m_pd_mutex);
A mini-server for performing network communication in the background.
static bool connect(const std::string &src, const std::string &dest, const std::string &carrier="", bool quiet=true)
Request that an output port connect to an input port.
static bool checkNetwork()
Check if the YARP Network is up and running.
void close() override
Stop port activity.
bool open(const std::string &name) override
Start port operation, with a specific name, with automatically-chosen network parameters.
bool isOpen() const
Check if the port has been opened.
A base class for nested structures that can be searched.
virtual bool check(const std::string &key) const =0
Check if there exists a property of the given name.
virtual Value & find(const std::string &key) const =0
Gets a value corresponding to a given keyword.
bool attachAsClient(yarp::os::UnbufferedContactable &port)
Tag this WireLink as a client, sending data via the specified port.
yarp::os::WireLink & yarp()
Get YARP state associated with this object.
#define yCError(component,...)
#define yCWarning(component,...)
#define YARP_LOG_COMPONENT(name,...)
For streams capable of holding different kinds of content, check what they actually have.
An interface to the operating system, including Port based communication.