Class: BGPView::Ip
- Inherits:
-
Object
- Object
- BGPView::Ip
- Defined in:
- lib/bgpview/ip.rb
Instance Method Summary collapse
-
#initialize(data) ⇒ Ip
constructor
A new instance of Ip.
- #method_missing(method, *args) ⇒ Object
Constructor Details
#initialize(data) ⇒ Ip
Returns a new instance of Ip.
5 6 7 |
# File 'lib/bgpview/ip.rb', line 5 def initialize(data) @data = data end |
Dynamic Method Handling
This class handles dynamic methods through the method_missing method
#method_missing(method, *args) ⇒ Object
9 10 11 12 13 14 15 |
# File 'lib/bgpview/ip.rb', line 9 def method_missing(method, *args) if @data.key?(method.to_sym) @data[method.to_sym] else super end end |