Class: GoodData::Bricks::BasePipeline
- Defined in:
- lib/gooddata/bricks/base_pipeline.rb
Direct Known Subclasses
Class Method Summary collapse
-
.prepare(pipeline) ⇒ Object
Pipeline preparation code.
Class Method Details
.prepare(pipeline) ⇒ Object
Pipeline preparation code
12 13 14 15 16 17 18 19 20 21 22 23 |
# File 'lib/gooddata/bricks/base_pipeline.rb', line 12 def self.prepare(pipeline) pipeline.reverse.reduce(nil) do |memo, app| if memo.nil? app.respond_to?(:new) ? app.new : app elsif app.respond_to?(:new) app.new(app: memo) else app.app = memo app end end end |