Class: Fall::Parser
- Inherits:
-
Object
- Object
- Fall::Parser
- Defined in:
- lib/fall/parser.rb
Instance Method Summary collapse
-
#initialize(string) ⇒ Parser
constructor
A new instance of Parser.
- #parse ⇒ Object
- #stages ⇒ Object
Constructor Details
#initialize(string) ⇒ Parser
Returns a new instance of Parser.
3 4 5 |
# File 'lib/fall/parser.rb', line 3 def initialize(string) @string = string end |
Instance Method Details
#parse ⇒ Object
12 13 14 15 16 17 |
# File 'lib/fall/parser.rb', line 12 def parse stages .then { identify_streams(_1) } .then { consolidate_streams(_1) } .then { create_operations(_1) } end |
#stages ⇒ Object
7 8 9 10 |
# File 'lib/fall/parser.rb', line 7 def stages @string.split('|') .map(&:strip) end |