Roboliq's default directives.
- Source:
Methods
-
<inner> directive_factorialMerge(spec)
-
Merge an array of objects, or combinatorially merge an array of arrays of objects.
Parameters:
Name Type Description specArray The array of objects or arrays of objects to merge.
Returns:
The object or array resulting from combinatorial merging.
- Type
- Object | Array
-
<inner> genMerge2(spec, data, obj0, index, acc)
-
Helper function for factorial merging of arrays of objects. For example, the first element of the first array is merged with the first element of the second array, added to the
acclist, then the first element of the first array is merged with the second element of the second array, and so on.Parameters:
Name Type Description specarray array of objects, may be nested arbitrarily deep, i.e. array of arrays of objects
dataobject [description]
obj0object accumulated result of the current merge, will be added to
acconce the end of thespeclist is reachedindexnumber index of current item in
specaccarray accumulated list of merged objects
Returns:
Returns a factorial list of merged objects.
- Type
- array