\ExtNets
Extended network pools implementation
Synopsis
class ExtNets
{
- // constants
- const EX_NOEXNET = 'NOT_EXISTING_NET_ID';
- const EX_NOEXPOOL = 'NOT_EXISTING_POOL_ID';
- const EX_NOEXIP = 'NOT_EXISTING_IP_ID';
- // members
- protected array $networks = ;
- protected array $pools = ;
- protected array $ips = ;
- protected array $switches = ;
- protected array $masklimits = ;
- protected array $cidrs = ;
- protected array $cidrToMask = ;
- protected array $cidrOffsets = ;
- // methods
- public void __construct()
- protected array v4CIDRtoMask()
- protected void preprocessCidrMasks()
- protected void loadNetworks()
- protected void loadPools()
- public string renderNetworks()
- public string getNetworkCidr()
- public string renderPools()
- protected int getFreePoolNet()
- public string poolCreateForm()
- public void poolCreate()
- public void poolDelete()
- protected void loadIps()
- protected array ipsGetByPool()
- protected void ipsDeleteByPool()
- protected void ipsCreate()
- protected string ipsGetAssociated()
- protected string poolEditForm()
- public void poolEdit()
- public string poolsExtractByLogin()
- protected void loadSwitches()
- protected string ipsEditForm()
- public void ipsEdit()
- public string renderIps()
- public string poolLinkingForm()
- public void poolLinkLogin()
- public string poolTemplateData()
Constants
Name | Value |
---|---|
EX_NOEXNET | 'NOT_EXISTING_NET_ID' |
EX_NOEXPOOL | 'NOT_EXISTING_POOL_ID' |
EX_NOEXIP | 'NOT_EXISTING_IP_ID' |
Members
protected
- $cidrOffsets
- $cidrToMask
- $cidrs
- $ips
- $masklimits
- $networks
- $pools
- $switches
Methods
protected
- getFreePoolNet() — returns last unused network address for new pool for some netid
- ipsCreate() — creates some ips range for newly created pool
- ipsDeleteByPool() — Deletes ips for some pool by ID
- ipsEditForm() — returns IP editin control
- ipsGetAssociated() — returns raw list of ips associated with some pool
- ipsGetByPool() — returns full list of associated IPs for some pool
- loadIps() — returns full list of associated IPs for all pools
- loadNetworks() — loads actual `other` networks array from database
- loadPools() — loads existing extpools from database into private pools property
- loadSwitches() — loads available switches array into private switches property
- poolEditForm() — Returns pool editing form
- preprocessCidrMasks() — prepare private CIDR mask data for following usage
- v4CIDRtoMask() — transform net/CIDR notation to netmask
public
- __construct()
- getNetworkCidr() — returns network CIDR by id
- ipsEdit() — edits some ip in database
- poolCreate() — Creates new address pool in database
- poolCreateForm() — returns new pool creation form
- poolDelete() — deletes existing pool by ID from database
- poolEdit() — Updates pool data into database
- poolLinkLogin() — changes pool login
- poolLinkingForm() — returns user attach pool control
- poolTemplateData() — returns data for docx templatizer for login and associated pools
- poolsExtractByLogin() — renders control links for pools associated with some login
- renderIps() — Renders ips associated with some poolid
- renderNetworks() — renders existing networks list accessible for pools assign
- renderPools() — renders available pools assigned by some network