Network::LocalSocket Class Reference

This class represent a local connection (client and server) More...

`#include <localsocket.hh>`

Inheritance diagram for Network::LocalSocket:

## Public Member Functions

| LocalSocket ()
| LocalSocket (PROTO_KIND pkind)
virtual | ~LocalSocket ()
void | writeto (const std::string &str, const std::string &filename)
| function used to send a msg to a specific named socket
std::string | read ()
| function used by >> operator (read a string on current socket)
std::string | read (int timeout)
| read a string with a timeout
std::string | read (std::string &filename)
| read a string and put the client named socket name in filename
std::string | read (std::string &filename, int timeout)
| read a string and put the client named socket name in filename with a timeout
std::string | readn (unsigned int size)
| read a string from socket
std::string | readn (int timeout, unsigned int size)
| read a string with a timeout
std::string | readn (std::string &filename, unsigned int size)
| read a string and put the client named socket name in filename
std::string | readn (std::string &filename, int timeout, unsigned int size)
| read a string and put the client named socket name in filename with a timeout
void | init (const std::string &filename)
| Here is an example of named server server using libsocket :
void | close ()
| connect to a local socket (client)
Public Member Functions inherited from Network::Socket
| Socket (SOCKET_KIND kind, SOCKET_VERSION version=V4)
| Socket (SOCKET_KIND kind, PROTO_KIND pkind, SOCKET_VERSION version=V4)
virtual | ~Socket ()
void | write (const std::string &str)
| function used by << operator (write a string on current socket)
bool | connected () const
| return true when socket is connected
int | get_socket ()
| get socket (fd) warning: be very carefull with this method
void | add_delim (const std::string &delim)
| set the delimitor for the text mode
void | del_delim (const std::string &delim)
| delete this delimitor for the socket
void | allow_empty_lines ()
| , if set, empty lines will be returned in text procols (if not, they are skipped)
void | init_tls (GnuTLSKind kind, unsigned size=1024, const std::string &certfile="", const std::string &keyfile="", const std::string &trustfile="", const std::string &crlfile="")
void | enable_tls ()
| Enable TLS on socket.

## Protected Member Functions

int | _bind (const std::string &filename)
| Initialize a local socket connection (server in UDP) create a named socket with name filename.
std::string | _read_line (int socket)
| Get a line from socket (when used with textual protocol)
std::string | _read_line (int socket, std::string &filename)
| Get a line from socket and give client socket filename (for named socket) (when used with textual protocol)
std::string | _read_line_bin (int socket, unsigned int size)
| Get a line from socket (when used with binary protocol)
std::string | _read_line_bin (int socket, std::string &filename, unsigned int pkg_size)
| Get a line from socket and give client socket filename (for named socket) (when used with binary protocol)
void | _write_str (int socket, const std::string &str, const std::string &filename) const
| Write a string to a socket to a particular named socket (when used with textual protocol)
void | _write_str_bin (int socket, const std::string &str, const std::string &filename) const
| Write a string to a socket to a particular named socket (when used with binary protocol)
Protected Member Functions inherited from Network::Socket
void | _close (int socket) const
| Close a connnection.
void | _listen (int socket) const
| Listen on port.
void | _write_str (int socket, const std::string &str) const
| Write a string to a socket (when used with textual protocol)
void | _write_str_bin (int socket, const std::string &str) const
| Write a string to a socket (when used with binary protocol)
void | _set_timeout (bool enable, int socket, int timeout)
| set a timeout on a socket
std::pair< int, int > | _find_delim (const std::string &str, int start) const
bool | _update_buffer (std::pair< int, int > &delim, int &i, std::string &str)
| look delimiter and remove delimiter at begining of buffer if needed
bool | _check_answer (int res, std::string &str)
| return the content of the buffer is there is

## Protected Attributes

std::string | _filename
Protected Attributes inherited from Network::Socket
SOCKET_KIND | _kind
SOCKET_VERSION | _version
unsigned | _state_timeout
int | _socket
int | _recv_flags
struct sockaddr_in | _addr
PROTO_KIND | _proto_kind
std::list< std::string > | _delim
bool | _empty_lines
std::string | _buffer
bool | _tls

## Detailed Description

This class represent a local connection (client and server)

Author
  Julien Lemoine <speedblue at happycoders dot org>

Definition at line 34 of file localsocket.hh.

## Constructor & Destructor Documentation

## LocalSocket() [1/2]

Network::LocalSocket::LocalSocket | ( |  | ) |

inline

Definition at line 37 of file localsocket.hh.

:
Socket(LOCAL), _filename("")
{}
Network::LocalSocket::_filename
std::string _filename
Definition localsocket.hh:224
Network::Socket::Socket
Socket(SOCKET_KIND kind, SOCKET_VERSION version=V4)
Definition socket.cc:31
Network::LOCAL
@ LOCAL
Definition socket.hh:82

## LocalSocket() [2/2]

Network::LocalSocket::LocalSocket | ( | PROTO_KIND | pkind | ) |

inline

Definition at line 40 of file localsocket.hh.

:
Socket(LOCAL, pkind), _filename("")
{}

## ~LocalSocket()

virtual Network::LocalSocket::~LocalSocket | ( |  | ) |

inline virtual

Definition at line 44 of file localsocket.hh.

{
close();
}
Network::LocalSocket::close
void close()
connect to a local socket (client)
Definition localsocket.cc:40

References close().

## Member Function Documentation

## _bind()

int Network::LocalSocket::_bind | ( | const std::string & | filename | ) |

protected

Initialize a local socket connection (server in UDP) create a named socket with name filename.

Exceptions

  NoConnection | when there is no open socket
  BindError | when bind libc function return a negative value

Definition at line 49 of file localsocket.cc.

{
int s;
struct sockaddr_un name;
size_t size;
s = socket(PF_UNIX, SOCK_DGRAM, 0);
if (s < 0)
throw NoConnection("Socket error", HERE);
name.sun_family = AF_UNIX;
strncpy(name.sun_path, filename.c_str(), sizeof (name.sun_path));
name.sun_path[sizeof (name.sun_path) - 1] = '\0';
size = (offsetof (struct sockaddr_un, sun_path)
+ strlen (name.sun_path) + 1);
if (bind (s, (struct sockaddr *) &name, size) < 0)
throw BindError("Bind error", HERE);
return s;
}
HERE
#define HERE
Definition socketexception.hh:26

References HERE.

Referenced by init().

## _read_line() [1/2]

std::string Network::LocalSocket::_read_line | ( | int | socket | ) |

protected virtual

Get a line from socket (when used with textual protocol)

Exceptions

  NoConnection | when there is no open socket
  ConnectionClosed | when there is no more connection

Implements Network::Socket.

Definition at line 212 of file localsocket.cc.

{
char chr[MAXPKTSIZE];
std::string str = "";
int res = 1, i;
std::pair<int, int> delim;
bool end = false;
if (socket < 0)
throw NoConnection("No Socket", HERE);
if (!_update_buffer(delim, i, str))
while (!end)
{
memset(chr, 0, MAXPKTSIZE);
#ifdef __CYGWIN__
res = recv(socket, chr, MAXPKTSIZE, 0);
#else
res = recv(socket, chr, MAXPKTSIZE, MSG_TRUNC);
#endif
if (res <= 0)
throw ConnectionClosed("Connection Closed", HERE);
_buffer += std::string(chr, res);
if (_update_buffer(delim, i, str))
end = true;
}
_state_timeout = 0;
return str;
}
Network::Socket::_buffer
std::string _buffer
Definition socket.hh:202
Network::Socket::_state_timeout
unsigned _state_timeout
Definition socket.hh:192
Network::Socket::_update_buffer
bool _update_buffer(std::pair< int, int > &delim, int &i, std::string &str)
look delimiter and remove delimiter at begining of buffer if needed
Definition socket.hxx:45

References Network::Socket::_buffer, Network::Socket::_state_timeout, Network::Socket::_update_buffer(), and HERE.

Referenced by read(), read(), read(), and read().

## _read_line() [2/2]

std::string Network::LocalSocket::_read_line | ( | int | socket,
|  | std::string & | filename
| ) |  |

protected

Get a line from socket and give client socket filename (for named socket) (when used with textual protocol)

Exceptions

  NoConnection | when there is no open socket
  ConnectionClosed | when there is no more connection

Definition at line 120 of file localsocket.cc.

{
char chr[MAXPKTSIZE];
std::string str = "";
int res = 1, i;
std::pair<int, int> delim;
struct sockaddr_un addr;
size_t size;
bool end = false;
size = sizeof(addr);
if (socket < 0)
throw NoConnection("No Socket", HERE);
if (!_update_buffer(delim, i, str))
while (!end)
{
#ifdef __CYGWIN__
res = recvfrom(socket, chr, MAXPKTSIZE, 0,
(struct sockaddr*)&addr,
(socklen_t*)&size);
#else
res = recvfrom(socket, chr, MAXPKTSIZE, MSG_TRUNC,
(struct sockaddr*)&addr,
(socklen_t*)&size);
#endif
if (res <= 0)
throw ConnectionClosed("Connection Closed", HERE);
_buffer += std::string(chr, res);
if (_update_buffer(delim, i, str))
end = true;
}
filename = std::string(addr.sun_path);
_state_timeout = 0;
return str;
}

References Network::Socket::_buffer, Network::Socket::_state_timeout, Network::Socket::_update_buffer(), and HERE.

## _read_line_bin() [1/2]

std::string Network::LocalSocket::_read_line_bin | ( | int | socket,
|  | std::string & | filename,
|  | unsigned int | pkg_size
| ) |  |

protected

Get a line from socket and give client socket filename (for named socket) (when used with binary protocol)

Exceptions

  NoConnection | when there is no open socket
  ConnectionClosed | when there is no more connection

Definition at line 241 of file localsocket.cc.

{
char chr[MAXPKTSIZE];
std::string str = "";
int res = 1;
struct sockaddr_un addr;
size_t size;
bool end = false;
size = sizeof(addr);
if (socket < 0)
throw NoConnection("No Socket", HERE);
if (_buffer.size() >= 2 && !pkg_size)
{
pkg_size = (unsigned char)_buffer[0] * 256 + (unsigned char)_buffer[1];
_buffer = _buffer.substr(2, _buffer.size() - 2);
}
if (pkg_size && _buffer.size() >= pkg_size)
{
str = _buffer.substr(0, pkg_size);
_buffer = _buffer.substr(pkg_size, _buffer.size() - pkg_size);
}
else
while (!end)
{
#ifdef __CYGWIN__
res = recvfrom(socket, chr, MAXPKTSIZE, 0,
(struct sockaddr*)&addr,
(socklen_t*)&size);
#else
res = recvfrom(socket, chr, MAXPKTSIZE, MSG_TRUNC,
(struct sockaddr*)&addr,
(socklen_t*)&size);
#endif
if (res <= 0)
throw ConnectionClosed("Connection Closed", HERE);
// _buffer += all octets received
_buffer += std::string(chr, res).substr(0, res);
if (!pkg_size)
{
// extract size from _buffer and reduce it
pkg_size = (unsigned char)_buffer[0] * 256 +
(unsigned char)_buffer[1];
_buffer = _buffer.substr(2, _buffer.size() - 2);
}
if (_buffer.size() > pkg_size - str.size())
{
str += _buffer.substr(0, pkg_size - str.size());
_buffer = _buffer.substr(pkg_size - str.size(),
_buffer.size() - pkg_size - str.size());
}
else
{
str += _buffer;
_buffer = "";
}
if (str.size() >= pkg_size)
end = true;
}
filename = std::string(addr.sun_path);
return str;
}

References Network::Socket::_buffer, and HERE.

## _read_line_bin() [2/2]

std::string Network::LocalSocket::_read_line_bin | ( | int | socket,
|  | unsigned int | size
| ) |  |

protected virtual

Get a line from socket (when used with binary protocol)

Exceptions

  NoConnection | when there is no open socket
  ConnectionClosed | when there is no more connection

Implements Network::Socket.

Definition at line 157 of file localsocket.cc.

{
char chr[MAXPKTSIZE];
std::string str = "";
int res = 1;
bool end = false;
if (socket < 0)
throw NoConnection("No Socket", HERE);
if (_buffer.size() >= 2 && !size)
{
size = (unsigned char)_buffer[0] * 256 + (unsigned char)_buffer[1];
_buffer = _buffer.substr(2, _buffer.size() - 2);
}
if (size && _buffer.size() >= size)
{
str = _buffer.substr(0, size);
_buffer = _buffer.substr(size, _buffer.size() - size);
}
else
while (!end)
{
memset(chr, 0, MAXPKTSIZE);
#ifdef __CYGWIN__
res = recv(socket, chr, MAXPKTSIZE, 0);
#else
res = recv(socket, chr, MAXPKTSIZE, MSG_TRUNC);
#endif
if (res <= 0)
throw ConnectionClosed("Connection Closed", HERE);
// _buffer += all octets received
_buffer += std::string(chr, res);
if (!size)
{
// extract size from _buffer and reduce it
size = (unsigned char)_buffer[0] * 256 + (unsigned char)_buffer[1];
_buffer = _buffer.substr(2, _buffer.size() - 2);
}
if (_buffer.size() > size - str.size())
{
str += _buffer.substr(0, size - str.size());
_buffer = _buffer.substr(size - str.size(),
_buffer.size() - size - str.size());
}
else
{
str += _buffer;
_buffer = "";
}
if (str.size() >= size)
end = true;
}
return str;
}

References Network::Socket::_buffer, and HERE.

Referenced by read(), read(), read(), read(), readn(), readn(), readn(), and readn().

## _write_str()

void Network::LocalSocket::_write_str | ( | int | socket,
|  | const std::string & | str,
|  | const std::string & | filename
| ) |  | const

protected

Write a string to a socket to a particular named socket (when used with textual protocol)

Exceptions

  NoConnection | when there is no open socket
  ConnectionClosed | when there is no more connection

Definition at line 68 of file localsocket.cc.

{
int res = 1;
const char *buf = str.c_str();
unsigned int count = 0;
struct sockaddr_un name;
name.sun_family = AF_UNIX;
strncpy(name.sun_path, filename.c_str(), sizeof (name.sun_path));
name.sun_path[sizeof (name.sun_path) - 1] = '\0';
if (socket < 0)
throw NoConnection("No Socket", HERE);
while (res && count < str.size())
{
res = sendto(socket, buf + count,
str.size() - count, SENDTO_FLAGS,
(const struct sockaddr*)&name, sizeof(name));
if (res <= 0)
throw ConnectionClosed("Connection Closed", HERE);
count += res;
}
}
SENDTO_FLAGS
#define SENDTO_FLAGS
Definition socket.hh:48

References HERE, and SENDTO_FLAGS.

Referenced by writeto().

## _write_str_bin()

void Network::LocalSocket::_write_str_bin | ( | int | socket,
|  | const std::string & | str,
|  | const std::string & | filename
| ) |  | const

protected

Write a string to a socket to a particular named socket (when used with binary protocol)

Exceptions

  NoConnection | when there is no open socket
  ConnectionClosed | when there is no more connection

Definition at line 93 of file localsocket.cc.

{
int res = 1;
unsigned int count = 0;
struct sockaddr_un name;
char buf[str.size() + 2];
buf[0] = str.size() / 256;
buf[1] = str.size() % 256;
memcpy(buf + 2, str.c_str(), str.size());
name.sun_family = AF_UNIX;
strncpy(name.sun_path, filename.c_str(), sizeof (name.sun_path));
name.sun_path[sizeof (name.sun_path) - 1] = DEFAULT_DELIM;
if (socket < 0)
throw NoConnection("No Socket", HERE);
while (res && count < str.size() + 2)
{
res = sendto(socket, buf + count, str.size() + 2 - count, SENDTO_FLAGS,
(const struct sockaddr*)&name, sizeof(name));
if (res <= 0)
throw ConnectionClosed("Connection Closed", HERE);
count += res;
}
}

References HERE, and SENDTO_FLAGS.

Referenced by writeto().

## close()

void Network::LocalSocket::close | ( |  | ) |

connect to a local socket (client)

Definition at line 40 of file localsocket.cc.

{
if (_socket > 0)
_close(_socket);
_socket = 0;
unlink(_filename.c_str());
_filename = "";
}
Network::Socket::_socket
int _socket
Definition socket.hh:193
Network::Socket::_close
void _close(int socket) const
Close a connnection.
Definition socket.cc:167

References Network::Socket::_close(), _filename, and Network::Socket::_socket.

Referenced by ~LocalSocket().

## init()

void Network::LocalSocket::init | ( | const std::string & | filename | ) |

Here is an example of named server server using libsocket :

      #include <stdlib.h>
      #include <iostream>
      #include <string>
      #include "socket/localsocket.hh"

      int main(int argc, char **argv)
      {
        Network::LocalSocket                server;
        std::string                 filename, client, str("");

        if (argc < 2)
          {
            std::cout << "Use: " << argv[0] << " filename" << std::endl;
            exit(0);
          }
        try
          {
            filename = std::string(argv[1]);
            server.init(filename);
            while (str != "quit")
            {
              //server.read(filename 30); //read with a timeout of 30 seconds
              //server >> str; //read without geting the named name
              //(cannot sent data)
              str = server.read(client);
              std::string msg = "ok, I received [" + str + "]";
              server.writeto(msg, client);
              std::cout << "[" << str << "] from : " << client << std::endl;
            }
            server.close();
            exit (0);
          }
        catch (Network::Timeout e)
          {
            std::cerr << e;
            std::cerr << "No connection during last 30s, closing connection"
                    << std::endl;
            exit (1);
          }
        catch (Network::Exception e)
          {
            std::cerr << e;
            exit(1);
          }
      }

Here is an example of named server server using libsocket :

    #include <stdlib.h>
      #include <iostream>
      #include <string>
      #include "socket/localsocket.hh"

      int main(int argc, char **argv)
      {
        Network::LocalSocket                client;
        std::string                 client_filename, server_filename, str(""), msg;

        if (argc < 3)
          {
            std::cout << "Use: " << argv[0] << " <client_filename> "
                    << "<server_filename>" << std::endl;
            exit(0);
          }
        try
          {
            client_filename = std::string(argv[1]);
            server_filename = std::string(argv[2]);

            client.init(client_filename);
            while (str != "quit")
            {
              std::cout << "Msg: ";
              std::cin >> str;
              client.writeto(str, server_filename);
              client >> msg;
              std::cout << "[received] " << msg << std::endl;
            }
            client.close();
            exit (0);
          }
        catch (Network::Timeout e)
          {
            std::cerr << e;
            std::cerr << "No connection during last 30s, closing connection"
                    << std::endl;
            exit (1);
          }
        catch (Network::Exception e)
          {
            std::cerr << e;
            exit(1);
          }
      }

Initialize a local socket (server)

Definition at line 34 of file localsocket.cc.

{
_socket = _bind(filename);
_filename = filename;
}
Network::LocalSocket::_bind
int _bind(const std::string &filename)
Initialize a local socket connection (server in UDP) create a named socket with name filename.
Definition localsocket.cc:49

References _bind(), _filename, and Network::Socket::_socket.

## read() [1/4]

std::string Network::LocalSocket::read | ( |  | ) |

virtual

function used by >> operator (read a string on current socket)

Implements Network::Socket.

Definition at line 352 of file localsocket.cc.

{
if (_proto_kind == binary)
return _read_line_bin(_socket, 0);
else
return _read_line(_socket);
}
Network::LocalSocket::_read_line
std::string _read_line(int socket)
Get a line from socket (when used with textual protocol)
Definition localsocket.cc:212
Network::LocalSocket::_read_line_bin
std::string _read_line_bin(int socket, unsigned int size)
Get a line from socket (when used with binary protocol)
Definition localsocket.cc:157
Network::Socket::_proto_kind
PROTO_KIND _proto_kind
Definition socket.hh:199
Network::binary
@ binary
Definition socket.hh:75

References Network::Socket::_proto_kind, _read_line(), _read_line_bin(), Network::Socket::_socket, and Network::binary.

## read() [2/4]

std::string Network::LocalSocket::read | ( | int | timeout | ) |

virtual

read a string with a timeout

Implements Network::Socket.

Definition at line 360 of file localsocket.cc.

{
if (_proto_kind == binary)
{
_set_timeout(true, _socket, timeout);
return _read_line_bin(_socket, 0);
}
else
{
_state_timeout = timeout;
return _read_line(_socket);
}
}
Network::Socket::_set_timeout
void _set_timeout(bool enable, int socket, int timeout)
set a timeout on a socket
Definition socket.cc:272

References Network::Socket::_proto_kind, _read_line(), _read_line_bin(), Network::Socket::_set_timeout(), Network::Socket::_socket, Network::Socket::_state_timeout, and Network::binary.

## read() [3/4]

std::string Network::LocalSocket::read | ( | std::string & | filename | ) |

read a string and put the client named socket name in filename

Definition at line 374 of file localsocket.cc.

{
if (_proto_kind)
return _read_line_bin(_socket, filename, 0);
else
return _read_line(_socket, filename);
}

References Network::Socket::_proto_kind, _read_line(), _read_line_bin(), and Network::Socket::_socket.

## read() [4/4]

std::string Network::LocalSocket::read | ( | std::string & | filename,
|  | int | timeout
| ) |  |

read a string and put the client named socket name in filename with a timeout

Definition at line 382 of file localsocket.cc.

{
if (_proto_kind == binary)
{
_set_timeout(true, _socket, timeout);
return _read_line_bin(_socket, filename, 0);
}
else
{
_state_timeout = timeout;
return _read_line(_socket, filename);
}
}

References Network::Socket::_proto_kind, _read_line(), _read_line_bin(), Network::Socket::_set_timeout(), Network::Socket::_socket, Network::Socket::_state_timeout, and Network::binary.

## readn() [1/4]

std::string Network::LocalSocket::readn | ( | int | timeout,
|  | unsigned int | size
| ) |  |

virtual

read a string with a timeout

Parameters

  size | represente the number of byte to read

Implements Network::Socket.

Definition at line 323 of file localsocket.cc.

{
if (!size || size > _buffer.size())
_set_timeout(true, _socket, timeout);
// _read_line_bin is bufferised with the same buffer as textual
// protocols, so this function can be used for binary and text
// protocols.
return _read_line_bin(_socket, size);
}

References Network::Socket::_buffer, _read_line_bin(), Network::Socket::_set_timeout(), and Network::Socket::_socket.

## readn() [2/4]

std::string Network::LocalSocket::readn | ( | std::string & | filename,
|  | int | timeout,
|  | unsigned int | size
| ) |  |

read a string and put the client named socket name in filename with a timeout

Parameters

  size | represente the number of byte to read

Definition at line 341 of file localsocket.cc.

{
if (!size || size > _buffer.size())
_set_timeout(true, _socket, timeout);
// _read_line_bin is bufferised with the same buffer as textual
// protocols, so this function can be used for binary and text
// protocols.
return _read_line_bin(_socket, filename, size);
}

References Network::Socket::_buffer, _read_line_bin(), Network::Socket::_set_timeout(), and Network::Socket::_socket.

## readn() [3/4]

std::string Network::LocalSocket::readn | ( | std::string & | filename,
|  | unsigned int | size
| ) |  |

read a string and put the client named socket name in filename

Parameters

  size | represente the number of byte to read

Definition at line 333 of file localsocket.cc.

{
// _read_line_bin is bufferised with the same buffer as textual
// protocols, so this function can be used for binary and text
// protocols.
return _read_line_bin(_socket, filename, size);
}

References _read_line_bin(), and Network::Socket::_socket.

## readn() [4/4]

std::string Network::LocalSocket::readn | ( | unsigned int | size | ) |

virtual

read a string from socket

Parameters

  size | represente the number of byte to read

Implements Network::Socket.

Definition at line 315 of file localsocket.cc.

{
// _read_line_bin is bufferised with the same buffer as textual
// protocols, so this function can be used for binary and text
// protocols.
return _read_line_bin(_socket, size);
}

References _read_line_bin(), and Network::Socket::_socket.

## writeto()

void Network::LocalSocket::writeto | ( | const std::string & | str,
|  | const std::string & | filename
| ) |  |

function used to send a msg to a specific named socket

Definition at line 306 of file localsocket.cc.

{
if (_proto_kind == binary)
_write_str_bin(_socket, str, filename);
else
_write_str(_socket, str, filename);
}
Network::LocalSocket::_write_str
void _write_str(int socket, const std::string &str, const std::string &filename) const
Write a string to a socket to a particular named socket (when used with textual protocol)
Definition localsocket.cc:68
Network::LocalSocket::_write_str_bin
void _write_str_bin(int socket, const std::string &str, const std::string &filename) const
Write a string to a socket to a particular named socket (when used with binary protocol)
Definition localsocket.cc:93

References Network::Socket::_proto_kind, Network::Socket::_socket, _write_str(), _write_str_bin(), and Network::binary.

## Member Data Documentation

## _filename

std::string Network::LocalSocket::_filename

protected

Definition at line 224 of file localsocket.hh.

Referenced by close(), and init().

The documentation for this class was generated from the following files:

- localsocket.hh
- localsocket.cc