Exception: Roby::InvalidReplace
- Defined in:
- lib/roby/standard_errors.rb
Overview
Raised by Plan#replace when the new task cannot replace the older one.
Instance Attribute Summary collapse
-
#from ⇒ Object
readonly
The task being replaced.
-
#to ⇒ Object
readonly
The task which should have replaced #from.
Instance Method Summary collapse
-
#initialize(from, to) ⇒ InvalidReplace
constructor
Create a new InvalidReplace object.
-
#pretty_print(pp) ⇒ Object
:nodoc:.
Constructor Details
#initialize(from, to) ⇒ InvalidReplace
Create a new InvalidReplace object
499 500 501 502 503 |
# File 'lib/roby/standard_errors.rb', line 499 def initialize(from, to) super() @from, @to = from, to end |
Instance Attribute Details
#from ⇒ Object (readonly)
The task being replaced
494 495 496 |
# File 'lib/roby/standard_errors.rb', line 494 def from @from end |
#to ⇒ Object (readonly)
The task which should have replaced #from
496 497 498 |
# File 'lib/roby/standard_errors.rb', line 496 def to @to end |
Instance Method Details
#pretty_print(pp) ⇒ Object
:nodoc:
505 506 507 508 509 510 511 512 513 |
# File 'lib/roby/standard_errors.rb', line 505 def pretty_print(pp) # :nodoc: pp.text "invalid replacement: #{}" pp.breakable pp.text "from " from.pretty_print(pp) pp.breakable pp.text "to " to.pretty_print(pp) end |