1 #ifndef __JNET__JHOSTNAME__ 
    2 #define __JNET__JHOSTNAME__ 
   17 namespace JPP { 
using namespace JNET; }
 
   89       return (this->hostname == 
hostname.hostname  &&
 
  104     void set(
const std::string& buffer)
 
  108       const string::size_type pos = buffer.find(
SEPARATOR);
 
  110       if (pos != string::npos) {
 
  112         this->
hostname = buffer.substr(0, pos);
 
  114         istringstream(buffer.substr(pos + 1)) >> this->
port;
 
  118         bool is_number = 
true;
 
  120         for (string::const_iterator i = buffer.begin(); is_number && i != buffer.end(); ++i) {
 
  121           is_number &= isdigit(*i);
 
  128           istringstream(buffer) >> this->
port;
 
  167       return out << 
object.hostname << 
SEPARATOR << 
object.port;
 
static const int DISPATCH_PORT
Default ControlHost port.
 
This name space includes all other name spaces (except KM3NETDAQ, KM3NET and ANTARES).
 
Template definition of auxiliary base class for comparison of data structures.
 
Auxiliary data structure for hostname and port number.
 
JHostname()
Default constructor.
 
friend std::ostream & operator<<(std::ostream &out, const JHostname &object)
Write hostname to output stream.
 
static const char SEPARATOR
Separation character between hostname and port number.
 
JHostname(const std::string &hostname, const int port)
Constructor.
 
void set(const std::string &buffer)
Set hostname and port number.
 
JHostname(const std::string &buffer)
Constructor.
 
friend std::istream & operator>>(std::istream &in, JHostname &object)
Read hostname from input stream.
 
bool equals(const JHostname &hostname) const
Equal method.