-
-/**
- @class wxIPaddress
-
- wxIPaddress is an abstract base class for all internet protocol address
- objects. Currently, only wxIPV4address is implemented. An experimental
- implementation for IPV6, wxIPV6address, is being developed.
-
- @library{wxbase}
- @category{net}
-*/
-class wxIPaddress : public wxSockAddress
-{
-public:
- /**
- Internally, this is the same as setting the IP address to @b INADDR_ANY.
-
- On IPV4 implementations, 0.0.0.0
-
- On IPV6 implementations, ::
-
- @return @true on success, @false if something went wrong.
- */
- virtual bool AnyAddress();
-
- /**
- Internally, this is the same as setting the IP address to @b INADDR_BROADCAST.
-
- On IPV4 implementations, 255.255.255.255
-
- @return @true on success, @false if something went wrong.
- */
- virtual bool BroadcastAddress();
-
- /**
- Set the address to hostname, which can be a host name or an IP-style address
- in a format dependent on implementation.
-
- @return @true on success, @false if something goes wrong (invalid
- hostname or invalid IP address).
- */
- virtual bool Hostname(const wxString& hostname);
-
- /**
- Returns the hostname which matches the IP address.
- */
- virtual wxString Hostname();
-
- /**
- Returns a wxString containing the IP address.
- */
- virtual wxString IPAddress();
-
- /**
- Determines if current address is set to localhost.
-
- @return @true if address is localhost, @false if internet address.
- */
- virtual bool IsLocalHost();
-
- /**
- Set address to localhost.
-
- On IPV4 implementations, 127.0.0.1
-
- On IPV6 implementations, ::1
-
- @return @true on success, @false if something went wrong.
- */
- virtual bool LocalHost();
-
- /**
- Set the port to that corresponding to the specified service.
-
- @return @true on success, @false if something goes wrong (invalid @a service).
- */
- virtual bool Service(const wxString& service);
-
- /**
- Set the port to that corresponding to the specified service.
-
- @return @true on success, @false if something goes wrong (invalid @a service).
- */
- virtual bool Service(unsigned short service);
-
- /**
- Returns the current service.
- */
- virtual unsigned short Service();
-};
-
-
-