A class to make it easier to handle and pass around IP addresses. More...

#include <IpAddress.h>

Inheritance diagram for IpAddress:
[legend]
Collaboration diagram for IpAddress:
[legend]

Public Member Functions

 IpAddress ()
 
 IpAddress (uint8_t first_octet, uint8_t second_octet, uint8_t third_octet, uint8_t fourth_octet)
 
 IpAddress (uint32_t address)
 
 IpAddress (ip_addr address)
 
 IpAddress (const uint8_t *address)
 
 IpAddress (const String &address)
 
 operator uint32_t () const
 
 operator ip_addr () const
 
 operator ip_addr * ()
 
bool operator== (const IpAddress &addr) const
 
bool operator== (const uint8_t *addr) const
 
bool operator!= (const IpAddress &addr) const
 
bool operator!= (const uint8_t *addr) const
 
bool isNull () const
 
String toString () const
 
bool compare (const IpAddress &addr, const IpAddress &mask) const
 
uint8_t operator[] (int index) const
 
uint8_t & operator[] (int index)
 
IpAddressoperator= (const uint8_t *address)
 
IpAddressoperator= (uint32_t address)
 
IpAddressoperator= (const String address)
 
size_t printTo (Print &p) const override
 

Detailed Description

A class to make it easier to handle and pass around IP addresses.

Constructor & Destructor Documentation

◆ IpAddress() [1/6]

IpAddress::IpAddress ( )
inline

◆ IpAddress() [2/6]

IpAddress::IpAddress ( uint8_t  first_octet,
uint8_t  second_octet,
uint8_t  third_octet,
uint8_t  fourth_octet 
)
inline

◆ IpAddress() [3/6]

IpAddress::IpAddress ( uint32_t  address)
inline

◆ IpAddress() [4/6]

IpAddress::IpAddress ( ip_addr  address)
inline

◆ IpAddress() [5/6]

IpAddress::IpAddress ( const uint8_t *  address)
inline

◆ IpAddress() [6/6]

IpAddress::IpAddress ( const String address)
inline

Member Function Documentation

◆ compare()

bool IpAddress::compare ( const IpAddress addr,
const IpAddress mask 
) const
inline

◆ isNull()

bool IpAddress::isNull ( ) const
inline

◆ operator ip_addr()

IpAddress::operator ip_addr ( ) const
inline

◆ operator ip_addr *()

IpAddress::operator ip_addr * ( )
inline

◆ operator uint32_t()

IpAddress::operator uint32_t ( ) const
inline

◆ operator!=() [1/2]

bool IpAddress::operator!= ( const IpAddress addr) const
inline

◆ operator!=() [2/2]

bool IpAddress::operator!= ( const uint8_t *  addr) const
inline

◆ operator=() [1/3]

IpAddress& IpAddress::operator= ( const uint8_t *  address)
inline

◆ operator=() [2/3]

IpAddress& IpAddress::operator= ( uint32_t  address)
inline

◆ operator=() [3/3]

IpAddress& IpAddress::operator= ( const String  address)
inline

◆ operator==() [1/2]

bool IpAddress::operator== ( const IpAddress addr) const
inline

◆ operator==() [2/2]

bool IpAddress::operator== ( const uint8_t *  addr) const
inline

◆ operator[]() [1/2]

uint8_t IpAddress::operator[] ( int  index) const
inline

◆ operator[]() [2/2]

uint8_t& IpAddress::operator[] ( int  index)
inline

◆ printTo()

size_t IpAddress::printTo ( Print p) const
overridevirtual

Implements Printable.

◆ toString()

String IpAddress::toString ( ) const

The documentation for this class was generated from the following file: