Defined in file: hzEmaddr.h

The hzDomain class imposes a data type of domain name. Domain names are a special case of a string with a defined form namely:- hzDomain can only accept string values that comply with this form

Constructors/Detructors

hzDomain*hzDomain(void)
hzDomain*hzDomain(hzDomain& dom)
hzDomain*hzDomain(const char* cpEMAddr)
hzDomain*hzDomain(hzString& dom)
void~hzDomain(void)

Public Methods:

voidClear(void)Clear the contents Arguments: None Returns: None
uint32_tCopies(void)Return number of copies for diagnostics
const char*GetDomain(void)Return domain name as null terminated string
const char*GetTLD(void)Return whole domain name as null terminated string
uint32_tLength(void)Return length in bytes of the whole domain name
void_dec_copy(void)
void_inc_copy(void)
uint32_t_int_addr(void)
void_int_clr(void)
void_int_set(uint32_t addr)
boolvalid(void)

Overloaded operators:

const char*hzDomain :: operator const char *(void)Returns the string data (a null terminated string) Arguments: None
const char*operator const char *(void)
booloperator!(void)
booloperator!=(const char* cpStr)Test for inequality between this hzDomain and an domain name held in a character string
booloperator!=(hzString& S)Test for inequality between this hzDomain and an domain name held in a hzString
const char*operator*(void)Returns the URL data (a null terminated string) Arguments: None
booloperator<(hzDomain& E)Return true if this hzDomain instance is lexically less than the operand. Note that comparison is first done on the domain part (the RHS of the @) and then done on the address part (the LHS of the @)
ostream&operator<<(ostream& os)hzDomain& ema,
booloperator<=(hzDomain& E)Return true if this hzDomain instance is lexically less than or equal to the operand. Note that comparison is first done on the domain part (the RHS of the @) and then done on the address part (the LHS of the @)
hzDomain&operator=(const char* cpStr)Assign the hzDomain to an domain name held in a character string Note: This function will record an E_FORMAT error if the supplied cstr did not amount to an domain name
hzDomain&operator=(hzString& S)Assign the hzDomain to an domain name held in a hzString instance Note: This function will record an E_FORMAT error if the supplied cstr did not amount to an domain name
hzDomain&operator=(hzChain::Iter& ci)Determines if the supplied iterator is at the start of a valid domain name and if it is, assignes this as the value to the calling instance.
hzDomain&operator=(hzDomain& dom)Assign the hzDomain to an domain name held in another hzDomain instance
booloperator==(hzDomain& E)Test for equality between this hzDomain and an operand instance
booloperator==(const char* cpStr)Test for equality between this hzDomain and an domain name held in a character string
booloperator==(hzString& S)Test for equality between this hzDomain and an domain name held in a hzString
booloperator>(hzDomain& E)Return true if this hzDomain instance is lexically greater than the operand. Note that comparison is first done on the domain part (the RHS of the @) and then done on the address part (the LHS of the @)
booloperator>=(hzDomain& E)Return true if this hzDomain instance is lexically greater than or equal to the operand. Note that comparison is first done on the domain part (the RHS of the @) and then done on the address part (the LHS of the @)

Member Variables:

uint32_tm_addrEncoded address of data space and control