1
0
mirror of https://github.com/MontFerret/ferret.git synced 2024-12-16 11:37:36 +02:00
ferret/pkg/runtime/collections/reducer.go
2018-09-18 16:42:38 -04:00

22 lines
363 B
Go

package collections
import (
"context"
"github.com/MontFerret/ferret/pkg/runtime/core"
)
type (
Reducer interface {
Reduce(collection core.Value, value core.Value) (core.Value, error)
}
Reducible interface {
Reduce() Reducer
}
ReducibleExpression interface {
core.Expression
Reduce(ctx context.Context, scope *core.Scope) (Reducer, error)
}
)