Dv::Net Namespace Reference

Classes

class  InetAddress
 A Dv::Net::InetAddress object represents a valid internet host. More...
class  SimpleMessage
 A SimpleMessage wraps a byte array which it may or may not own. More...
class  Message
 Template extension of SimpleMessage. More...
class  Message< std::string >
 Specialization for string. More...
class  ServerSocket
 A class representing an internet server. More...
class  Socket
 Provide a network connection as an iostream. More...
class  userversocket
 Class representing a server listening on a unix socket. More...
class  usocket
 Unix socket iostream specialization. More...
class  usockstreambuf
 Dv::Util::fdstreambuf specialization for unix sockets. More...

Functions

void parse_host_port (const std::string &host_port, std::string &host, int &port) throw (std::runtime_error)
 Parse a string of the form "host:port" into its constitiuents.
void setup_unsocket (const std::string &filename, sockaddr_un &addr, socklen_t &len) throw (std::runtime_error)
 Auxiliary function: initialize addr from filename.

Function Documentation

void Dv::Net::parse_host_port ( const std::string &  host_port,
std::string &  host,
int &  port 
) throw (std::runtime_error)

Parse a string of the form "host:port" into its constitiuents.

Parameters:
host_port a string of the form "host:port", e.g. "tinf2.vub.ac.be:80"
host the host part of the host_port parameter.
port the port number from the host_port parameter
Exceptions:
std::runtime_error if host_port is malformed
void Dv::Net::setup_unsocket ( const std::string &  filename,
sockaddr_un &  addr,
socklen_t &  len 
) throw (std::runtime_error)

Auxiliary function: initialize addr from filename.

Parameters:
filename 
addr to initialize from filename
len of addr?

dvnet-0.9.24 [ 5 December, 2009]