YARP
Yet Another Robot Platform
Contactable.cpp
Go to the documentation of this file.
1 /*
2  * Copyright (C) 2006-2020 Istituto Italiano di Tecnologia (IIT)
3  * Copyright (C) 2006-2010 RobotCub Consortium
4  * All rights reserved.
5  *
6  * This software may be modified and distributed under the terms of the
7  * BSD-3-Clause license. See the accompanying LICENSE file for details.
8  */
9 
10 #include <yarp/os/Contactable.h>
11 
13 
14 
16 
17 std::string yarp::os::Contactable::getName() const
18 {
19  return where().getName();
20 }
21 
23 {
24  setInputMode(true);
25  setOutputMode(false);
26  setRpcMode(false);
27 }
28 
30 {
31  setInputMode(false);
32  setOutputMode(true);
33  setRpcMode(false);
34 }
35 
37 {
38  setInputMode(true);
39  setOutputMode(false);
40  setRpcMode(true);
41 }
42 
44 {
45  setInputMode(false);
46  setOutputMode(true);
47  setRpcMode(true);
48 }
yarp::os::Contact::getName
std::string getName() const
Get the name associated with this Contact.
Definition: Contact.cpp:208
yarp::os::Contactable::setRpcServer
void setRpcServer()
Shorthand for setInputMode(true), setOutputMode(false), setRpcMode(true)
Definition: Contactable.cpp:36
yarp::os::Contactable::setWriteOnly
void setWriteOnly()
Shorthand for setInputMode(false), setOutputMode(true), setRpcMode(false)
Definition: Contactable.cpp:29
yarp::os::Contactable::setRpcClient
void setRpcClient()
Shorthand for setInputMode(false), setOutputMode(true), setRpcMode(true)
Definition: Contactable.cpp:43
yarp::os::Contactable::~Contactable
virtual ~Contactable()
Destructor.
yarp::os::Contactable::where
virtual Contact where() const =0
Returns information about how this port can be reached.
yarp::os::Contactable::getName
virtual std::string getName() const
Get name of port.
Definition: Contactable.cpp:17
AbstractContactable.h
Contactable.h
yarp::os::Contactable::setReadOnly
void setReadOnly()
Shorthand for setInputMode(true), setOutputMode(false), setRpcMode(false)
Definition: Contactable.cpp:22