Class: Bosh::Director::IpUtil::CIDRIP
- Defined in:
- lib/bosh/director/ip_util.rb
Instance Method Summary collapse
-
#initialize(ip) ⇒ CIDRIP
constructor
A new instance of CIDRIP.
- #to_i ⇒ Object
- #to_s ⇒ Object
Constructor Details
#initialize(ip) ⇒ CIDRIP
Returns a new instance of CIDRIP.
70 71 72 73 74 75 76 |
# File 'lib/bosh/director/ip_util.rb', line 70 def initialize(ip) if ip.kind_of?(NetAddr::CIDR) @cidr = ip else @cidr = NetAddr::CIDR.create(ip) end end |