Arion 1.0.2-alpha
A high-performance C++ framework for emulating executable binaries.
 
Loading...
Searching...
No Matches
arion::ARION_SOCKET Struct Reference

This structure holds data about a UNIX socket. More...

#include <socket_manager.hpp>

Public Member Functions

 ARION_SOCKET ()
 
 ARION_SOCKET (int fd, int family, int type, int protocol)
 
 ARION_SOCKET (std::shared_ptr< ARION_SOCKET > s)
 
 ARION_SOCKET (ARION_SOCKET *s)
 
 ~ARION_SOCKET ()
 

Public Attributes

int fd
 File Descriptor of the socket.
 
int family
 UNIX family of the socket (e.g, AF_UNIX, AF_INET).
 
int type
 UNIX type of the socket (e.g, SOCK_STREAM, SOCK_DGRAM).
 
int protocol
 UNIX protocol of the socket.
 
std::string ip
 IP address associated to the socket, when relevant.
 
uint16_t port
 Port associated to the socket, when relevant.
 
std::string path
 Path associated to the socket, when relevant.
 
bool server = false
 Whether this socket acts as a server.
 
bool server_listen = false
 Whether this socket acts as a server and listens to incoming requests.
 
int server_backlog = 0
 If this socket acts as a server, size of the queue in which other sockets await for connection.
 
bool blocking = false
 Whether this socket is in blocking mode.
 
socklen_t s_addr_sz = 0
 Length of the socket sockaddr address, when relevant.
 
sockaddr * s_addr = nullptr
 The socket sockaddr address, when relevant.
 

Detailed Description

This structure holds data about a UNIX socket.

Constructor & Destructor Documentation

◆ ARION_SOCKET() [1/4]

arion::ARION_SOCKET::ARION_SOCKET ( )
inline

Builder for ARION_SOCKET instances.

◆ ARION_SOCKET() [2/4]

arion::ARION_SOCKET::ARION_SOCKET ( int  fd,
int  family,
int  type,
int  protocol 
)
inline

Builder for ARION_SOCKET instances.

Parameters
[in]fdFile Descriptor of the socket.
[in]familyUNIX family of the socket (e.g, AF_UNIX, AF_INET).
[in]typeUNIX type of the socket (e.g, SOCK_STREAM, SOCK_DGRAM).
[in]protocolUNIX protocol of the socket.

◆ ARION_SOCKET() [3/4]

arion::ARION_SOCKET::ARION_SOCKET ( std::shared_ptr< ARION_SOCKET s)
inline

Builder for ARION_SOCKET instances used to clone an ARION_SOCKET instance.

Parameters
[in]sthe ARION_SOCKET instance to be cloned.

◆ ARION_SOCKET() [4/4]

arion::ARION_SOCKET::ARION_SOCKET ( ARION_SOCKET s)
inline

Builder for ARION_SOCKET instances used to clone an ARION_SOCKET instance.

Parameters
[in]sthe ARION_SOCKET instance to be cloned.

◆ ~ARION_SOCKET()

arion::ARION_SOCKET::~ARION_SOCKET ( )
inline

Destructor for ARION_SOCKET instances.

Member Data Documentation

◆ blocking

bool arion::ARION_SOCKET::blocking = false

Whether this socket is in blocking mode.

◆ family

int arion::ARION_SOCKET::family

UNIX family of the socket (e.g, AF_UNIX, AF_INET).

◆ fd

int arion::ARION_SOCKET::fd

File Descriptor of the socket.

◆ ip

std::string arion::ARION_SOCKET::ip

IP address associated to the socket, when relevant.

◆ path

std::string arion::ARION_SOCKET::path

Path associated to the socket, when relevant.

◆ port

uint16_t arion::ARION_SOCKET::port

Port associated to the socket, when relevant.

◆ protocol

int arion::ARION_SOCKET::protocol

UNIX protocol of the socket.

◆ s_addr

sockaddr* arion::ARION_SOCKET::s_addr = nullptr

The socket sockaddr address, when relevant.

◆ s_addr_sz

socklen_t arion::ARION_SOCKET::s_addr_sz = 0

Length of the socket sockaddr address, when relevant.

◆ server

bool arion::ARION_SOCKET::server = false

Whether this socket acts as a server.

◆ server_backlog

int arion::ARION_SOCKET::server_backlog = 0

If this socket acts as a server, size of the queue in which other sockets await for connection.

◆ server_listen

bool arion::ARION_SOCKET::server_listen = false

Whether this socket acts as a server and listens to incoming requests.

◆ type

int arion::ARION_SOCKET::type

UNIX type of the socket (e.g, SOCK_STREAM, SOCK_DGRAM).


The documentation for this struct was generated from the following file: