Class: Fino::Pipeline

Inherits:
Object
  • Object
show all
Extended by:
Forwardable
Defined in:
lib/fino/pipeline.rb

Instance Method Summary collapse

Constructor Details

#initialize(storage, pipes = []) ⇒ Pipeline

Returns a new instance of Pipeline.



8
9
10
11
# File 'lib/fino/pipeline.rb', line 8

def initialize(storage, pipes = [])
  @storage = storage
  @pipes = pipes
end

Instance Method Details

#use(pipe_class) ⇒ Object



13
14
15
16
# File 'lib/fino/pipeline.rb', line 13

def use(pipe_class, ...)
  pipes << ->(pipe) { pipe_class.new(pipe, ...) }
  @pipeline = nil
end