Class: QuietQuality::Tools::Outcome
- Inherits:
-
Object
- Object
- QuietQuality::Tools::Outcome
- Defined in:
- lib/quiet_quality/tools/outcome.rb
Instance Attribute Summary collapse
-
#logging ⇒ Object
readonly
Returns the value of attribute logging.
-
#output ⇒ Object
readonly
Returns the value of attribute output.
-
#tool ⇒ Object
readonly
Returns the value of attribute tool.
Instance Method Summary collapse
- #==(other) ⇒ Object
- #failure? ⇒ Boolean
-
#initialize(tool:, output:, logging: nil, failure: false) ⇒ Outcome
constructor
A new instance of Outcome.
- #success? ⇒ Boolean
Constructor Details
#initialize(tool:, output:, logging: nil, failure: false) ⇒ Outcome
Returns a new instance of Outcome.
6 7 8 9 10 11 |
# File 'lib/quiet_quality/tools/outcome.rb', line 6 def initialize(tool:, output:, logging: nil, failure: false) @tool = tool @output = output @logging = logging @failure = failure end |
Instance Attribute Details
#logging ⇒ Object (readonly)
Returns the value of attribute logging.
4 5 6 |
# File 'lib/quiet_quality/tools/outcome.rb', line 4 def logging @logging end |
#output ⇒ Object (readonly)
Returns the value of attribute output.
4 5 6 |
# File 'lib/quiet_quality/tools/outcome.rb', line 4 def output @output end |
#tool ⇒ Object (readonly)
Returns the value of attribute tool.
4 5 6 |
# File 'lib/quiet_quality/tools/outcome.rb', line 4 def tool @tool end |
Instance Method Details
#==(other) ⇒ Object
21 22 23 |
# File 'lib/quiet_quality/tools/outcome.rb', line 21 def ==(other) tool == other.tool && output == other.output && logging == other.logging && failure? == other.failure? end |
#failure? ⇒ Boolean
13 14 15 |
# File 'lib/quiet_quality/tools/outcome.rb', line 13 def failure? @failure end |
#success? ⇒ Boolean
17 18 19 |
# File 'lib/quiet_quality/tools/outcome.rb', line 17 def success? !failure? end |