interface Function<V : Serializable, A : Serializable, D>
(source)
Interface for the decomposable aggregation function α ≔ 〈f, g, h〉 supported by the DB-tree.
The decomposable aggregation function α is defined such that α(v₁, ... , vₙ) = h(f(g(v₁), ... , g(vₙ))), where:
g: V -> A
f: A₁, ..., Aₙ -> A (core aggregation function)
h: A -> D
V
- the type of the atomic values stored in the DB-tree.
A
- the type of the aggregate values.
D
- the final result type, calculated over the final aggregate value.
f |
Function's component for the combination of aggregate values. abstract fun f(aggList: List<A?>): A? |
g |
Computes the aggregate value from an atomic value. abstract fun g(v: V?): A? |
h |
Generates a final result from an aggregate value. abstract fun h(a: A?): D? |
identity |
Returns the identity aggregate value for this aggregation function. abstract fun identity(): A? |
parseA |
Parser for the aggregate value type. abstract fun parseA(s: String): A? |
parseV |
Parser for the atomic value type. abstract fun parseV(s: String): V? |
AverageInt |
class AverageInt : Function<Int, Pair<Long, Long>, Long> |
CountInt |
class CountInt : Function<Int, Long, Long> |
HashInt |
class HashInt : Function<Int, String, String> |
MaxInt |
class MaxInt : Function<Int, Int, Int> |
MinInt |
class MinInt : Function<Int, Int, Int> |
SumCountInt |
class SumCountInt : Function<Int, Pair<Long, Long>, Pair<Long, Long>> |
SumInt |
class SumInt : Function<Int, Long, Long> |