Class: Nmap::Scan
- Inherits:
-
Struct
- Object
- Struct
- Nmap::Scan
- Defined in:
- lib/nmap/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.
19 20 21 |
# File 'lib/nmap/scan.rb', line 19 def initialize(type,protocol,services=[]) super(type,protocol,services) end |
Instance Attribute Details
#protocol ⇒ Object
Returns the value of attribute protocol
5 6 7 |
# File 'lib/nmap/scan.rb', line 5 def protocol @protocol end |
#services ⇒ Object
Returns the value of attribute services
5 6 7 |
# File 'lib/nmap/scan.rb', line 5 def services @services end |
#type ⇒ Object
Returns the value of attribute type
5 6 7 |
# File 'lib/nmap/scan.rb', line 5 def type @type end |
Instance Method Details
#to_s ⇒ String
Converts the scan to a String.
29 30 31 |
# File 'lib/nmap/scan.rb', line 29 def to_s "#{self.protocol} #{self.type}" end |