Class: WarCorrespondent::Reporters::Net
- Inherits:
-
WarCorrespondent::Reporter
- Object
- WarCorrespondent::Reporter
- WarCorrespondent::Reporters::Net
- Defined in:
- lib/warcorrespondent/reporters/net.rb
Instance Attribute Summary
Attributes inherited from WarCorrespondent::Reporter
#identifier, #options, #timeout
Instance Method Summary collapse
-
#initialize(args) ⇒ Net
constructor
A new instance of Net.
Methods inherited from WarCorrespondent::Reporter
Constructor Details
#initialize(args) ⇒ Net
Returns a new instance of Net.
4 5 6 7 8 9 10 11 12 13 |
# File 'lib/warcorrespondent/reporters/net.rb', line 4 def initialize(args) @block = Proc.new do SystemInformation::net.map{ |net_id,data| data.map{ |type, value| {:identifier => "net:#{net_id.to_s}:#{type.to_s}", :value => value } } }.inject([]){|a,b|a+b} end super(args) end |