fixed NetworkInterface for Windows

This commit is contained in:
Guenter Obiltschnig
2008-09-17 15:43:14 +00:00
parent 296913bd93
commit f5c33e77fb
2 changed files with 67 additions and 20 deletions

View File

@@ -1,7 +1,7 @@
//
// NetworkInterface.h
//
// $Id: //poco/svn/Net/include/Poco/Net/NetworkInterface.h#2 $
// $Id: //poco/1.3/Net/include/Poco/Net/NetworkInterface.h#5 $
//
// Library: Net
// Package: Sockets
@@ -91,6 +91,15 @@ public:
const std::string& name() const;
/// Returns the interface name.
const std::string& displayName() const;
/// Returns the interface display name.
///
/// On Windows platforms, this is currently the network adapter
/// name. This may change to the "friendly name" of the network
/// connection in a future version, however.
///
/// On other platforms this is the same as name().
const IPAddress& address() const;
/// Returns the IP address bound to the interface.
@@ -140,10 +149,10 @@ public:
/// the same interface.
protected:
NetworkInterface(const std::string& name, const IPAddress& address, int index = -1);
NetworkInterface(const std::string& name, const std::string& displayName, const IPAddress& address, int index = -1);
/// Creates the NetworkInterface.
NetworkInterface(const std::string& name, const IPAddress& address, const IPAddress& subnetMask, const IPAddress& broadcastAddress, int index = -1);
NetworkInterface(const std::string& name, const std::string& displayName, const IPAddress& address, const IPAddress& subnetMask, const IPAddress& broadcastAddress, int index = -1);
/// Creates the NetworkInterface.
IPAddress interfaceNameToAddress(const std::string& interfaceName) const;