-
Notifications
You must be signed in to change notification settings - Fork 3
Open
Labels
Description
The branch aggregation contains a new interface and new operators for aggregation:
t, _ := s.PutAgg(f, x...): Put a tuple to spacesobtained by using a user defined aggregation functionfon the tuples matched by a templatex.... If no tuples are matched, the templatex...is converted to its intrinsic tuple, that is, the concrete values read from the template itself, and put insinstead.t, _ := s.GetAgg(f, x...): Get a tuple from spacesobtained by using a user defined aggregation functionfon the tuples matched by a templatex..., while removing the tuples in the process.t, _ := s.QueryAgg(f, x...): Query for a tuple from spacesobtained by using a user defined aggregation functionfon the tuples matched by a templatex..., leaving spacesintact.
All operators are non-blocking and return a copy of aggregate tuple t. The returned copy can be ignored.
Below is a visualisation of the three operators PutAgg(), GetAgg() and QueryAgg(). t corresponds to a tuple returned, while template T = x.... The empty tuple is (), and small crosses, circles and squares indicate tuples of possibly different type.
The interface referred to here will be referred to as the Star Library.
