Class: Umwelt::Tree::Imprint
- Inherits:
-
Abstract::Interactor
- Object
- Abstract::Interactor
- Umwelt::Tree::Imprint
- Defined in:
- lib/umwelt/tree/imprint.rb
Instance Method Summary collapse
- #call(semantic_name) ⇒ Object
-
#initialize(trunk, location: nil) ⇒ Imprint
constructor
A new instance of Imprint.
Methods inherited from Abstract::Interactor
Constructor Details
#initialize(trunk, location: nil) ⇒ Imprint
Returns a new instance of Imprint.
7 8 9 10 11 |
# File 'lib/umwelt/tree/imprint.rb', line 7 def initialize(trunk, location: nil) @trunk = trunk @location = location @written_paths = {} end |
Instance Method Details
#call(semantic_name) ⇒ Object
13 14 15 16 17 18 19 |
# File 'lib/umwelt/tree/imprint.rb', line 13 def call(semantic_name) error! not_clean unless location_clean? @trunk.nodes.map do |node| write node.semantic(semantic_name) end end |