NetmaskGroup¶
-
newNMG():
NetmaskGroup¶ Returns a NetmaskGroup
- class NetmaskGroup¶
Represents a group of netmasks that can be used to match
ComboAddresses against.- addMask(mask)¶
- addMasks(masks)¶
Add one or more masks to the NMG.
- Parameters:¶
mask (
string) – Add this mask, prefix with!to exclude this mask from matching.masks (
table) – Adds the keys of the table to theNetmaskGroup. It should be a table whose keys areComboAddressobjects and whose values are integers. The integer values of the table entries are ignored. The table is of the same type as the table returned by the exceed* functions.
-
addNMG(otherNMG:
NetmaskGroup)¶ Added in version 1.9.0.
Add all masks from an existing NMG to this NMG.
- Parameters:¶
otherNMG (
NetmaskGroup) – Add the masks from aNetmaskGroupto this one.
-
match(address:
ComboAddress):bool¶ Checks if
addressis matched by this NetmaskGroup.- Parameters:¶
address (
ComboAddress) – The address to match.
- clear()¶
Clears the NetmaskGroup.
-
size():
int¶ Returns number of netmasks in this NetmaskGroup.