Woman, Life, Freedom


Async BSD Sockets Library
Library protected and public interface header documentation
communicator.h
1#ifndef COMMUNICATOR_H
2#define COMMUNICATOR_H
3
4#include <unistd.h>
5
6namespace AsyncBsdSocketLib
7{
10 {
11 protected:
14
15 Communicator() noexcept;
16
17 public:
18 virtual ~Communicator() noexcept;
19
22 int Descriptor() const noexcept;
23
26 virtual int Connection() const noexcept = 0;
27
30 virtual bool TrySetup() noexcept = 0;
31
34 virtual bool TryClose() noexcept;
35 };
36}
37
38#endif
Communication method (i.e., network sockets and named pipes)
Definition: communicator.h:10
int FileDescriptor
File descriptor.
Definition: communicator.h:13
int Descriptor() const noexcept
File descriptor.
virtual bool TryClose() noexcept
Try to close the communicator.
virtual bool TrySetup() noexcept=0
Try to setup the communicator.
virtual int Connection() const noexcept=0
Connection descriptor for sending and receiving.