Class: Nmap::RunStat

Inherits:
Struct
  • Object
show all
Defined in:
lib/nmap/run_stat.rb

Overview

Represents the runstats of a scan.

Since:

  • 0.7.0

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#elapsedObject

Returns the value of attribute elapsed

Returns:

  • (Object)

    the current value of elapsed



7
8
9
# File 'lib/nmap/run_stat.rb', line 7

def elapsed
  @elapsed
end

#end_timeObject

Returns the value of attribute end_time

Returns:

  • (Object)

    the current value of end_time



7
8
9
# File 'lib/nmap/run_stat.rb', line 7

def end_time
  @end_time
end

#exit_statusObject

Returns the value of attribute exit_status

Returns:

  • (Object)

    the current value of exit_status



7
8
9
# File 'lib/nmap/run_stat.rb', line 7

def exit_status
  @exit_status
end

#summaryObject

Returns the value of attribute summary

Returns:

  • (Object)

    the current value of summary



7
8
9
# File 'lib/nmap/run_stat.rb', line 7

def summary
  @summary
end

Instance Method Details

#to_sString

Converts the stats to a String.

Returns:

  • (String)

    The String form of the scan.

Since:

  • 0.7.0



15
16
17
# File 'lib/nmap/run_stat.rb', line 15

def to_s
  "#{self.end_time} #{self.elapsed} #{self.exit_status}"
end