Auxiliary data structure for hostname and port number.  
 More...
#include <JHostname.hh>
 | 
| static const char  | SEPARATOR = ':' | 
|   | Separation character between hostname and port number.  More...
  | 
|   | 
Auxiliary data structure for hostname and port number. 
Definition at line 33 of file JHostname.hh.
 
  
  
      
        
          | JNET::JHostname::JHostname  | 
          ( | 
           | ) | 
           | 
         
       
   | 
  
inline   | 
  
 
 
  
  
      
        
          | JNET::JHostname::JHostname  | 
          ( | 
          const std::string &  | 
          buffer | ) | 
           | 
         
       
   | 
  
inline   | 
  
 
Constructor. 
The argument correponds to the hostname and an optional port number of the server. The syntax is hostname[:port]. The default port number is DISPATCH_PORT. If the complete buffer corresponds to an integer value, it is interpreted as the port number.
- Parameters
 - 
  
    | buffer | host name and optional port number  | 
  
   
Definition at line 61 of file JHostname.hh.
void set(const std::string &buffer)
Set hostname and port number. 
 
 
 
 
  
  
      
        
          | JNET::JHostname::JHostname  | 
          ( | 
          const std::string &  | 
          hostname,  | 
         
        
           | 
           | 
          const int  | 
          port  | 
         
        
           | 
          ) | 
           |  | 
         
       
   | 
  
inline   | 
  
 
Constructor. 
- Parameters
 - 
  
    | hostname | hostname  | 
    | port | port number  | 
  
   
Definition at line 73 of file JHostname.hh.
 
 
  
  
      
        
          | bool JNET::JHostname::equals  | 
          ( | 
          const JHostname &  | 
          hostname | ) | 
           const | 
         
       
   | 
  
inline   | 
  
 
Equal method. 
- Parameters
 - 
  
    | hostname | host name and port  | 
  
   
- Returns
 - true if this host name and port is equal to given host name and port; else false 
 
Definition at line 87 of file JHostname.hh.
   89       return (this->hostname == hostname.
hostname  &&
 
then usage $script< detector file >< detectorfile > nIf the range of floors is the first detector file is aligned to the second before the comparison nIn this
 
 
 
 
  
  
      
        
          | void JNET::JHostname::set  | 
          ( | 
          const std::string &  | 
          buffer | ) | 
           | 
         
       
   | 
  
inline   | 
  
 
Set hostname and port number. 
The argument correponds to the hostname and an optional port number of the server.
The syntax is hostname[:port]. The default port number is DISPATCH_PORT.
If the complete buffer corresponds to an integer value, it is interpreted as the port number.
- Parameters
 - 
  
    | buffer | host name and optional port number  | 
  
   
Definition at line 104 of file JHostname.hh.
  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;
 
static const int DISPATCH_PORT
Default ControlHost port. 
 
static const char SEPARATOR
Separation character between hostname and port number. 
 
 
 
 
  
  
      
        
          | std::istream& operator>>  | 
          ( | 
          std::istream &  | 
          in,  | 
         
        
           | 
           | 
          JHostname &  | 
          object  | 
         
        
           | 
          ) | 
           |  | 
         
       
   | 
  
friend   | 
  
 
Read hostname from input stream. 
- Parameters
 - 
  
    | in | input stream  | 
    | object | hostname  | 
  
   
- Returns
 - input stream 
 
Definition at line 146 of file JHostname.hh.
then fatal Wrong number of arguments fi set_variable DETECTOR $argv[1] set_variable INPUT_FILE $argv[2] eval JPrintDetector a $DETECTOR O IDENTIFIER eval JPrintDetector a $DETECTOR O SUMMARY JAcoustics sh $DETECTOR_ID source JAcousticsToolkit sh CHECK_EXIT_CODE typeset A EMITTERS get_tripods $WORKDIR tripod txt EMITTERS get_transmitters $WORKDIR transmitter txt EMITTERS for EMITTER in
 
 
 
 
  
  
      
        
          | std::ostream& operator<<  | 
          ( | 
          std::ostream &  | 
          out,  | 
         
        
           | 
           | 
          const JHostname &  | 
          object  | 
         
        
           | 
          ) | 
           |  | 
         
       
   | 
  
friend   | 
  
 
Write hostname to output stream. 
- Parameters
 - 
  
    | out | output stream  | 
    | object | hostname  | 
  
   
- Returns
 - output stream 
 
Definition at line 165 of file JHostname.hh.
  167       return out << 
object.hostname << 
SEPARATOR << 
object.port;
 
static const char SEPARATOR
Separation character between hostname and port number. 
 
 
 
 
  
  
      
        
          | const char JNET::JHostname::SEPARATOR = ':' | 
         
       
   | 
  
static   | 
  
 
Separation character between hostname and port number. 
Definition at line 39 of file JHostname.hh.
 
 
      
        
          | int JNET::JHostname::port | 
        
      
 
 
The documentation for this struct was generated from the following file: