Sets the IP address to the value provided as a character string. The string must be of the form x.x.x.x where x can be any number between 0 and 255
| Return Type | Function name | Arguments |
|---|---|---|
| hzEcode | hzIpaddr::SetValue | (const char*,) |
Declared in file: hzIpaddr.h
Defined in file : hzIpaddr.cpp
Function Logic:
Function body:
hzEcode hzIpaddr::SetValue (const char* cpIpa)
{
// Sets the IP address to the value provided as a character string. The string must be of the form x.x.x.x where x can be any number between 0 and 255
//
// Arguments: 1) cpIpa IP address as a cstr
//
// Returns: E_NODATA If the input is not supplied
// E_FORMAT If the input cstr is no an IP address
// E_OK If this IP address instance is set
if (!cpIpa || !cpIpa[0])
return E_NODATA ;
if (IsIPAddr(m_Ipa, cpIpa))
return E_OK ;
return E_FORMAT ;
}