Module: ParamParam

Defined in:
lib/param_param.rb,
lib/param_param/std.rb,
lib/param_param/result.rb

Overview

It allows to define pipelines that transform hash values.

Each pipeline is bound to a particular key and processes a value related to that key. A pipeline consists of a chain of actions that are executed one by one. An actions receives a value from a previous action and is expected to return successful or failed result. A successful result contains a new value being the result of the processing. The new value is passed further in the chain to the next action. A failed result contains a message from an action saying why a particular value can’t be processed. Following actions in the chain are not executed.

Defined Under Namespace

Modules: Actions, Std Classes: Failure, Result, Success

Class Method Summary collapse

Class Method Details

.included(base) ⇒ Object



16
17
18
# File 'lib/param_param.rb', line 16

def self.included(base)
  base.extend(Actions)
end