Module: Merge

Merging module.
Source:

Members

(inner, constant) strategies :Object

Type:
  • Object
Properties:
Name Type Description
strategies Object Collection of strategies to aggregate PAD results. In order to aggregate new strategies, just add a new item to this object, and implement a function which receives an array of triplets and returns a single triplet. Then, add another case to the switch in the getMergingDataStrategy so there is a case which returns this brand new strategy.
Source:

Methods

(inner) applyStrategy(strategyName, tripletsArray) → {function}

Applies selected strategy to incoming data
Parameters:
Name Type Description
strategyName string String with the name of a strategy. This string should match one of the cases in the switch-case block of the getMergingDataStrategy function.
tripletsArray Array of triplets.
Source:
Returns:
Type
function

(inner) getMergingDataStrategy(strategyName) → {function}

Retrieves the function to use in the PAD results merging process.
Parameters:
Name Type Description
strategyName string String with the name of a strategy. This string should match one of the cases in the switch-case block of this function.
Source:
Returns:
Type
function