crossroads

Git mirror of https://crossroads.e-tunity.com/
git clone git://git.finwo.net/app/crossroads
Log | Files | Refs | LICENSE

servertype (353B)


      1 #ifndef _SERVERTYPE_
      2 #define _SERVERTYPE_
      3 
      4 #include <string>
      5 using namespace std;
      6 
      7 class Servertype {
      8 public:
      9     enum Type {
     10 	t_tcp,
     11 	t_http,
     12     };
     13 
     14     Servertype(): t(t_tcp) 		{ }
     15     Servertype(string id) 		{ type(id); }
     16 
     17     void type(string id);
     18     string typestr() const;
     19     Type type() const 			{ return t; }
     20 
     21 private:
     22     Type t;
     23 };
     24 
     25 #endif