Anonymous user
Module:IP: Difference between revisions
From the Croc Wiki, the Croc encyclopedia
Jump to navigationJump to search
use Subnet instead of IPBlock, plus some more interface ideas
(don't allow setting a new IP address in IPAddress objects - this doesn't make much sense) |
(use Subnet instead of IPBlock, plus some more interface ideas) |
||
Line 46:
end
function obj:
return false
end
function obj:getNextIP()
end
function obj:getPreviousIP()
end
Line 82 ⟶ 88:
--------------------------------------------------------------------------------
--
-- Represents a block of ipv4 or ipv6 addresses.
--------------------------------------------------------------------------------
local
do
Line 93 ⟶ 99:
-- Constructor
function
-- Set up structure
local obj = setmetatable({}, mt)
Line 102 ⟶ 108:
end
function obj:
end
function obj:getPrefix()
return '1.2.3.
end
function obj:getHighestIP()
return '1.2.3.255'
end
Line 131 ⟶ 141:
function obj:containsIP(ip)
return false
end
function obj:overlapsSubnet(subnet)
end
|