YARP
Yet Another Robot Platform
TcpConnector.h
Go to the documentation of this file.
1/*
2 * SPDX-FileCopyrightText: 2006-2021 Istituto Italiano di Tecnologia (IIT)
3 * SPDX-FileCopyrightText: 2010 Anne van Rossum <anne@almende.com>
4 * SPDX-License-Identifier: BSD-3-Clause
5 */
6
7#ifndef YARP_OS_IMPL_POSIX_TCPCONNECTOR_H
8#define YARP_OS_IMPL_POSIX_TCPCONNECTOR_H
9
10#include <yarp/os/Contact.h>
13
14
15namespace yarp {
16namespace os {
17namespace impl {
18namespace posix {
19
20
21/* **************************************************************************************
22 * Interface of TcpConnector
23 * **************************************************************************************/
24
26{
27public:
32
36 virtual ~TcpConnector();
37
38 int connect (TcpStream &new_stream,
39 const yarp::os::Contact &remote_address,
40 YARP_timeval* timeout = nullptr);
41protected:
42
43 int open(TcpStream &stream);
44private:
45
46};
47
48} // namespace posix
49} // namespace impl
50} // namespace os
51} // namespace yarp
52
53
54#endif // YARP_OS_IMPL_POSIX_TCPCONNECTOR_H
Represents how to reach a part of a YARP network.
Definition: Contact.h:33
TcpConnector()
Constructor TcpConnector.
virtual ~TcpConnector()
Destructor ~TcpConnector.
int connect(TcpStream &new_stream, const yarp::os::Contact &remote_address, YARP_timeval *timeout=nullptr)
Connect to server.
struct timeval YARP_timeval
Definition: PlatformTime.h:30
The main, catch-all namespace for YARP.
Definition: dirs.h:16