nis-util
1.0.D108
|
#include <services.h>
Public Types | |
typedef boost::shared_ptr< record > | pointer |
typedef std::list< rcstring > | aliases_t |
Public Member Functions | |
~record () | |
const source_location & | get_source_location (void) const |
rcstring | get_name (void) const |
rcstring | get_port (void) const |
int | get_port_binary (void) const |
rcstring | get_protocol (void) const |
const aliases_t & | get_aliases (void) const |
rcstring | representation (void) const |
Static Public Member Functions | |
static pointer | create (const source_location &locn, const rcstring &name, const rcstring &port, const rcstring &protocol, const aliases_t &aliases) |
Private Member Functions | |
record (const source_location &locn, const rcstring &name, const rcstring &port, const rcstring &protocol, const aliases_t &aliases) | |
Private Attributes | |
source_location | locn |
rcstring | name |
rcstring | port |
rcstring | protocol |
aliases_t | aliases |
The record class is used to represent one record from the services file. Values of this type are returned by the get method.
Definition at line 53 of file services.h.
typedef std::list<rcstring> space_services::record::aliases_t |
Definition at line 63 of file services.h.
typedef boost::shared_ptr<record> space_services::record::pointer |
Definition at line 56 of file services.h.
The destructor.
Definition at line 222 of file services.cc.
space_services::record::record | ( | const source_location & | locn, |
const rcstring & | name, | ||
const rcstring & | port, | ||
const rcstring & | protocol, | ||
const aliases_t & | aliases | ||
) | [private] |
The constructor. It is private on purpose, use the create class method instead.
Definition at line 227 of file services.cc.
space_services::record::pointer space_services::record::create | ( | const source_location & | locn, |
const rcstring & | name, | ||
const rcstring & | port, | ||
const rcstring & | protocol, | ||
const aliases_t & | aliases | ||
) | [static] |
The create class method is used to create new dynaically allocated instance of this class.
Definition at line 244 of file services.cc.
const aliases_t& space_services::record::get_aliases | ( | void | ) | const [inline] |
Definition at line 78 of file services.h.
rcstring space_services::record::get_name | ( | void | ) | const [inline] |
Definition at line 74 of file services.h.
rcstring space_services::record::get_port | ( | void | ) | const [inline] |
Definition at line 75 of file services.h.
int space_services::record::get_port_binary | ( | void | ) | const |
Definition at line 253 of file services.cc.
rcstring space_services::record::get_protocol | ( | void | ) | const [inline] |
Definition at line 77 of file services.h.
const source_location& space_services::record::get_source_location | ( | void | ) | const [inline] |
Definition at line 73 of file services.h.
rcstring space_services::record::representation | ( | void | ) | const |
The representation method is used to generate a string which represents the services entry, suitable for inserting into an services file or services map. (There is no newline on the end.)
Definition at line 264 of file services.cc.
aliases_t space_services::record::aliases [private] |
The aliases instance variable is used to remember the alternative names of the service.
Definition at line 125 of file services.h.
source_location space_services::record::locn [private] |
The locn instance variable is used to remember the source file location of the record.
Definition at line 101 of file services.h.
rcstring space_services::record::name [private] |
The name instance variable is used to remember the name of the service.
Definition at line 107 of file services.h.
rcstring space_services::record::port [private] |
The port instance variable is used to remember the port number (0..65535) of the service.
Definition at line 113 of file services.h.
rcstring space_services::record::protocol [private] |
The protocol instance variable is used to remember the protocol of the service.
Definition at line 119 of file services.h.