Class: CC::Analyzer::EngineOutput
- Inherits:
-
Object
- Object
- CC::Analyzer::EngineOutput
- Defined in:
- lib/cc/analyzer/engine_output.rb
Instance Method Summary collapse
- #as_issue ⇒ Object
- #error ⇒ Object
-
#initialize(raw_output) ⇒ EngineOutput
constructor
A new instance of EngineOutput.
- #issue? ⇒ Boolean
- #valid? ⇒ Boolean
Constructor Details
#initialize(raw_output) ⇒ EngineOutput
Returns a new instance of EngineOutput.
7 8 9 |
# File 'lib/cc/analyzer/engine_output.rb', line 7 def initialize(raw_output) @raw_output = raw_output end |
Instance Method Details
#as_issue ⇒ Object
17 18 19 |
# File 'lib/cc/analyzer/engine_output.rb', line 17 def as_issue Issue.new(raw_output) end |
#error ⇒ Object
25 26 27 |
# File 'lib/cc/analyzer/engine_output.rb', line 25 def error validator.error end |
#issue? ⇒ Boolean
11 12 13 14 15 |
# File 'lib/cc/analyzer/engine_output.rb', line 11 def issue? parsed_output && parsed_output["type"].present? && parsed_output["type"].downcase == "issue" end |
#valid? ⇒ Boolean
21 22 23 |
# File 'lib/cc/analyzer/engine_output.rb', line 21 def valid? validator.valid? end |