Module: Trebor::Domain
- Included in:
- Context, InnerDomain, Task
- Defined in:
- lib/trebor/domain.rb
Instance Attribute Summary collapse
-
#parent ⇒ Object
readonly
Returns the value of attribute parent.
Instance Method Summary collapse
Instance Attribute Details
#parent ⇒ Object (readonly)
Returns the value of attribute parent.
3 4 5 |
# File 'lib/trebor/domain.rb', line 3 def parent @parent end |
Instance Method Details
#current_directory ⇒ Object
9 10 11 |
# File 'lib/trebor/domain.rb', line 9 def current_directory parent && parent.current_directory end |
#fetch(command) ⇒ Object
5 6 7 |
# File 'lib/trebor/domain.rb', line 5 def fetch(command) parent ? parent.fetch(command) : command end |
#toplevel ⇒ Object
13 14 15 |
# File 'lib/trebor/domain.rb', line 13 def toplevel parent ? parent.toplevel : self end |