Namespace: Rx – Class: CRxIPv4Subnetmask – Header: Rx.Core/RxIPv4Subnetmask.h

CRxIPv4Subnetmask Class

C++
#include "Rx.Core/RxIPv4Subnetmask.h"
class CRxIPv4Subnetmask

Provides data and methods for processing an IPv4 subnet mask.

Constructors

CRxIPv4Subnetmask()

Default constructor.

CRxIPv4Subnetmask(uSubnetMask)

Constructor with unsigned as initialization. Interpreted in the way, that the first byte is oriented to the right: 0x00 00 FF FF – This would be 255.255.0.0.

CRxIPv4Subnetmask(ucSub1, ucSub2, ucSub3, ucSub4)

Constructor with single unsigned char values as arguments for initialization of the Subnet mask. Example for 255.255.0.0 would be:

CRxIPv4Subnetmask(sSubnetMask)

Constructor with a CRxString as initialization. Expected is a string with unsigned values separated by ".". Example: CRxString xIP = "255.255.0.0";.

CRxIPv4Subnetmask(xSubnetMask)

Copy constructor.

Methods

Set(sSubnetMask)

Sets the given string as new subnet mask. See comment for CRxIPv4Subnetmask().

Set(uSub)

Sets the given unsigned as new Subnet mask. Interpreted in the way, that the first byte is oriented to the right: 0x00 00 FF FF – This would be 255.255.0.0.

Set(ucSub1, ucSub2, ucSub3, ucSub4)

Like the constructor with the same arguments: Constructor with single unsigned char values as arguments for initialization of the subnet mask. Example for 255.255.0.0 would be:

Get()

Gets the subnet mask represented as an unsigned value. To be interpreted in the way, that the first byte is oriented to the right: 0x00 00 FF FF <– This would be 255.255.0.0.

GetRef()

Gets the reference to the subnet unsigned int member.

Get(ucSub1, ucSub2, ucSub3, ucSub4)

Gets the subnet mask with each of the 4 parts in a unsigned char. Example for 255.255.0.0 would be:

ToString()

Convert this CRxIPv4Subnetmask into a string representation. Example: "192.168.0.1".

IsValid()

Query if this CRxIPv4Subnetmask is valid.

Operators

operator[](uIdx)

Array indexer operator.

operator[](uIdx)

Array indexer operator.