Class: Tenable::Models::WebAppScan
- Inherits:
-
Data
- Object
- Data
- Tenable::Models::WebAppScan
- Defined in:
- lib/tenable/models/web_app_scan.rb
Overview
Represents a web application scan instance.
Instance Attribute Summary collapse
-
#completed_at ⇒ Object
readonly
Returns the value of attribute completed_at.
-
#config_id ⇒ Object
readonly
Returns the value of attribute config_id.
-
#findings_count ⇒ Object
readonly
Returns the value of attribute findings_count.
-
#scan_id ⇒ Object
readonly
Returns the value of attribute scan_id.
-
#started_at ⇒ Object
readonly
Returns the value of attribute started_at.
-
#status ⇒ Object
readonly
Returns the value of attribute status.
Class Method Summary collapse
-
.from_api(data) ⇒ WebAppScan
Builds a WebAppScan from a raw API response hash.
Instance Attribute Details
#completed_at ⇒ Object (readonly)
Returns the value of attribute completed_at
6 7 8 |
# File 'lib/tenable/models/web_app_scan.rb', line 6 def completed_at @completed_at end |
#config_id ⇒ Object (readonly)
Returns the value of attribute config_id
6 7 8 |
# File 'lib/tenable/models/web_app_scan.rb', line 6 def config_id @config_id end |
#findings_count ⇒ Object (readonly)
Returns the value of attribute findings_count
6 7 8 |
# File 'lib/tenable/models/web_app_scan.rb', line 6 def findings_count @findings_count end |
#scan_id ⇒ Object (readonly)
Returns the value of attribute scan_id
6 7 8 |
# File 'lib/tenable/models/web_app_scan.rb', line 6 def scan_id @scan_id end |
#started_at ⇒ Object (readonly)
Returns the value of attribute started_at
6 7 8 |
# File 'lib/tenable/models/web_app_scan.rb', line 6 def started_at @started_at end |
#status ⇒ Object (readonly)
Returns the value of attribute status
6 7 8 |
# File 'lib/tenable/models/web_app_scan.rb', line 6 def status @status end |
Class Method Details
.from_api(data) ⇒ WebAppScan
Builds a WebAppScan from a raw API response hash.
11 12 13 14 15 16 17 18 19 20 21 |
# File 'lib/tenable/models/web_app_scan.rb', line 11 def self.from_api(data) data = data.transform_keys(&:to_sym) new( scan_id: data[:scan_id], config_id: data[:config_id], status: data[:status], started_at: data[:started_at], completed_at: data[:completed_at], findings_count: data[:findings_count] || 0 ) end |