Class: Nexpose::ScanSummary::Nodes
- Inherits:
-
Object
- Object
- Nexpose::ScanSummary::Nodes
- Defined in:
- lib/nexpose/scan.rb
Overview
Value class for tracking node counts.
Instance Attribute Summary collapse
-
#dead ⇒ Object
readonly
Returns the value of attribute dead.
-
#filtered ⇒ Object
readonly
Returns the value of attribute filtered.
-
#live ⇒ Object
readonly
Returns the value of attribute live.
-
#other ⇒ Object
readonly
Returns the value of attribute other.
-
#unresolved ⇒ Object
readonly
Returns the value of attribute unresolved.
Class Method Summary collapse
-
.parse(rexml) ⇒ Nodes
Parse REXML to Nodes object.
Instance Method Summary collapse
-
#initialize(live, dead, filtered, unresolved, other) ⇒ Nodes
constructor
A new instance of Nodes.
Constructor Details
#initialize(live, dead, filtered, unresolved, other) ⇒ Nodes
Returns a new instance of Nodes.
579 580 581 |
# File 'lib/nexpose/scan.rb', line 579 def initialize(live, dead, filtered, unresolved, other) @live, @dead, @filtered, @unresolved, @other = live, dead, filtered, unresolved, other end |
Instance Attribute Details
#dead ⇒ Object (readonly)
Returns the value of attribute dead.
577 578 579 |
# File 'lib/nexpose/scan.rb', line 577 def dead @dead end |
#filtered ⇒ Object (readonly)
Returns the value of attribute filtered.
577 578 579 |
# File 'lib/nexpose/scan.rb', line 577 def filtered @filtered end |
#live ⇒ Object (readonly)
Returns the value of attribute live.
577 578 579 |
# File 'lib/nexpose/scan.rb', line 577 def live @live end |
#other ⇒ Object (readonly)
Returns the value of attribute other.
577 578 579 |
# File 'lib/nexpose/scan.rb', line 577 def other @other end |
#unresolved ⇒ Object (readonly)
Returns the value of attribute unresolved.
577 578 579 |
# File 'lib/nexpose/scan.rb', line 577 def unresolved @unresolved end |
Class Method Details
.parse(rexml) ⇒ Nodes
Parse REXML to Nodes object.
588 589 590 591 592 593 594 595 |
# File 'lib/nexpose/scan.rb', line 588 def self.parse(rexml) return nil unless rexml Nodes.new(rexml.attributes['live'].to_i, rexml.attributes['dead'].to_i, rexml.attributes['filtered'].to_i, rexml.attributes['unresolved'].to_i, rexml.attributes['other'].to_i) end |