Class: Nmap::XML::Scan
- Inherits:
-
Struct
- Object
- Struct
- Nmap::XML::Scan
- Defined in:
- lib/nmap/xml/scan.rb
Overview
Represents an Nmap scan.
Instance Attribute Summary collapse
-
#protocol ⇒ Object
Returns the value of attribute protocol.
-
#services ⇒ Object
Returns the value of attribute services.
-
#type ⇒ Object
Returns the value of attribute type.
Instance Method Summary collapse
-
#initialize(type, protocol, services = []) ⇒ Scan
constructor
Creates a new Scan object.
-
#to_s ⇒ String
Converts the scan to a String.
Constructor Details
#initialize(type, protocol, services = []) ⇒ Scan
Creates a new Scan object.
24 25 26 |
# File 'lib/nmap/xml/scan.rb', line 24 def initialize(type,protocol,services=[]) super(type,protocol,services) end |
Instance Attribute Details
#protocol ⇒ Object
Returns the value of attribute protocol
10 11 12 |
# File 'lib/nmap/xml/scan.rb', line 10 def protocol @protocol end |
#services ⇒ Object
Returns the value of attribute services
10 11 12 |
# File 'lib/nmap/xml/scan.rb', line 10 def services @services end |
#type ⇒ Object
Returns the value of attribute type
10 11 12 |
# File 'lib/nmap/xml/scan.rb', line 10 def type @type end |
Instance Method Details
#to_s ⇒ String
Converts the scan to a String.
34 35 36 |
# File 'lib/nmap/xml/scan.rb', line 34 def to_s "#{self.protocol} #{self.type}" end |