|
SatCat5
|
An IPv4 subnet consists of a base address and a subnet mask.
#include <ip_core.h>
Public Member Functions | |
| Subnet (const Subnet &t)=default | |
| Subnet & | operator= (const Subnet &t)=default |
| constexpr bool | contains (const satcat5::ip::Addr &other) const |
| Does this subnet contain the given address? | |
| unsigned | prefix () const |
| Get the CIDR prefix length for this subnet. | |
| void | log_to (satcat5::log::LogBuffer &wr) const |
| Format this subnet in CIDR form, e.g., "192.168.1.0/24". | |
| constexpr bool | operator== (const satcat5::ip::Addr &other) const |
| Commonly used operators. | |
| constexpr bool | operator== (const satcat5::ip::Subnet &other) const |
| Commonly used operators. | |
| constexpr bool | operator!= (const satcat5::ip::Subnet &other) const |
| Commonly used operators. | |
Public Attributes | |
| satcat5::ip::Addr | addr |
| Base address. | |
| satcat5::ip::Mask | mask |
| Subnet mask. | |