Starshatter_Open
Open source Starshatter engine
 All Classes Files Functions Variables Typedefs Enumerations Enumerator Friends Macros
NetHost.h
Go to the documentation of this file.
1 /* Project nGenEx
2  Destroyer Studios LLC
3  Copyright © 1997-2004. All Rights Reserved.
4 
5  SUBSYSTEM: NetEx.lib
6  FILE: NetHost.h
7  AUTHOR: John DiCamillo
8 
9 
10  OVERVIEW
11  ========
12  Network Host
13 */
14 
15 #ifndef NET_HOST_H
16 #define NET_HOST_H
17 
18 #include <windows.h>
19 #include "NetAddr.h"
20 #include "Text.h"
21 #include "List.h"
22 
23 // +-------------------------------------------------------------------+
24 
25 class NetHost
26 {
27 public:
28  static const char* TYPENAME() { return "NetHost"; }
29 
30  NetHost();
31  NetHost(const char* host_addr);
32  NetHost(const NetHost& n);
33  ~NetHost();
34 
35  const char* Name();
36  NetAddr Address();
37 
38  List<Text>& Aliases() { return aliases; }
39  List<NetAddr>& AddressList() { return addresses; }
40 
41 private:
42  void Init(const char* host_name);
43 
44  Text name;
45  List<Text> aliases;
46  List<NetAddr> addresses;
47 };
48 
49 
50 #endif // NET_HOST_H