public class FoldLeft extends Fold
ValueExpression implementation of the FoldLeft operation.
FoldLeft differs from FoldRight in that the reduce operation is
applied from left to right (i.e., starting at the top).
FoldRight| Constructor and Description |
|---|
FoldLeft(ValueExpression values,
BinaryOperator<ValueExpression> reducer,
ValueExpression initial) |
| Modifier and Type | Method and Description |
|---|---|
protected ImmutableList<Optional<Value>> |
prepareValues(ImmutableList<Optional<Value>> values) |
protected ValueExpression |
reduce(BinaryOperator<ValueExpression> reducer,
Value head,
Value tail) |
public FoldLeft(ValueExpression values, BinaryOperator<ValueExpression> reducer, ValueExpression initial)
protected ImmutableList<Optional<Value>> prepareValues(ImmutableList<Optional<Value>> values)
prepareValues in class Foldprotected ValueExpression reduce(BinaryOperator<ValueExpression> reducer, Value head, Value tail)
Copyright © 2017. All rights reserved.