|
LibSWOC++ 1.5.14
Solid Wall of C++
|
#include <IPAddr.h>

Classes | |
| union | raw_addr_type |
| Address data. More... | |
Public Member Functions | |
| IPAddr ()=default | |
| Default constructor - invalid result. | |
| IPAddr (self_type const &that)=default | |
| Copy constructor. | |
| self_type & | operator= (self_type const &that)=default |
| Copy assignment. | |
| IPAddr (in_addr_t addr) | |
| Construct using IPv4 addr. | |
| IPAddr (IP4Addr const &addr) | |
| Construct using an IPv4 addr. | |
| IPAddr (in6_addr const &addr) | |
| Construct using IPv6 addr. | |
| IPAddr (IP6Addr const &addr) | |
| construct using an IPv6 addr | |
| IPAddr (sockaddr const *addr) | |
Construct from sockaddr. | |
| IPAddr (IPEndpoint const &addr) | |
Construct from IPEndpoint. | |
| IPAddr (string_view const &text) | |
| self_type & | assign (sockaddr const *addr) |
| Set to the address in addr. | |
| self_type & | assign (sockaddr_in const *addr) |
| Set to the address in addr. | |
| self_type & | assign (sockaddr_in6 const *addr) |
| Set to the address in addr. | |
| self_type & | assign (in_addr_t addr) |
| Set to IPv4 addr. | |
| self_type & | assign (in6_addr const &addr) |
| Set to IPv6 addr. | |
| self_type & | operator= (IPEndpoint const &ip) |
| Assign from end point. | |
| self_type & | operator= (in_addr_t ip) |
| Assign from IPv4 raw address. | |
| self_type & | operator= (in6_addr const &addr) |
| Assign from IPv6 raw address. | |
| bool | operator== (self_type const &that) const |
| bool | operator!= (self_type const &that) const |
| bool | operator< (self_type const &that) const |
| bool | operator> (self_type const &that) const |
| bool | operator<= (self_type const &that) const |
| bool | operator>= (self_type const &that) const |
| self_type & | operator= (sockaddr const *addr) |
Assign from sockaddr. | |
| self_type & | operator&= (IPMask const &mask) |
| self_type & | operator|= (IPMask const &mask) |
| sockaddr * | copy_to (sockaddr *sa) const |
| bool | load (string_view const &text) |
| int | cmp (self_type const &that) const |
| Generic compare. | |
| bool | is_same_family (self_type const &that) |
| sa_family_t | family () const |
| bool | is_ip4 () const |
| Test for IPv4. | |
| bool | is_ip6 () const |
| Test for IPv6. | |
| IP4Addr const & | ip4 () const |
| operator IP4Addr () const | |
| IP6Addr const & | ip6 () const |
| operator IP6Addr () const | |
| bool | is_valid () const |
| Test for validity. | |
| self_type & | invalidate () |
| Make invalid. | |
| bool | is_loopback () const |
| Test for loopback. | |
| bool | is_multicast () const |
| Test for multicast. | |
| bool | is_link_local () const |
| bool | is_private () const |
| Pre-constructed invalid instance. | |
Static Public Attributes | |
| static self_type const | INVALID |
Protected Attributes | |
| friend | IP4Addr |
| friend | IP6Addr |
| union swoc::IPAddr::raw_addr_type | _addr |
| sa_family_t | _family {AF_UNSPEC} |
| Protocol family. | |
Friends | |
| class | IPRange |
An IPv4 or IPv6 address.
The family type is stored. For comparisons, invalid < IPv4 < IPv6. All invalid instances are equal.
|
inlineexplicit |
|
inline |
|
inlineexplicit |
|
inline |
|
inlineexplicit |
|
explicit |
Construct from IPEndpoint.
Definition at line 513 of file swoc_ip.cc.
|
inlineexplicit |
|
inline |
|
inline |
| IPAddr & swoc::IPAddr::assign | ( | sockaddr const * | addr | ) |
Set to the address in addr.
Definition at line 562 of file swoc_ip.cc.
|
inline |
|
inline |
| int swoc::IPAddr::cmp | ( | self_type const & | that | ) | const |
Generic compare.
Definition at line 602 of file swoc_ip.cc.
| sockaddr * swoc::IPAddr::copy_to | ( | sockaddr * | sa | ) | const |
Copy the address to a socket address.
| sa | Destination. |
Definition at line 523 of file swoc_ip.cc.
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
| bool swoc::IPAddr::is_multicast | ( | ) | const |
Test for multicast.
Definition at line 646 of file swoc_ip.cc.
|
inline |
|
inline |
|
inline |
| bool swoc::IPAddr::load | ( | string_view const & | text | ) |
Parse a string and load the result in this.
| text | Text to parse. |
true on success, false otherwise. Definition at line 533 of file swoc_ip.cc.
|
inlineexplicit |
|
inlineexplicit |
|
inline |
| IPAddr::self_type & swoc::IPAddr::operator&= | ( | IPMask const & | mask | ) |
Definition at line 626 of file swoc_ip.cc.
| bool swoc::IPAddr::operator< | ( | self_type const & | that | ) | const |
Definition at line 577 of file swoc_ip.cc.
|
inline |
|
inline |
|
inline |
| IPAddr & swoc::IPAddr::operator= | ( | IPEndpoint const & | ip | ) |
Assign from end point.
Definition at line 518 of file swoc_ip.cc.
|
inline |
|
inline |
|
inline |
|
inline |
| IPAddr::self_type & swoc::IPAddr::operator|= | ( | IPMask const & | mask | ) |
Definition at line 636 of file swoc_ip.cc.
|
protected |