Add typed aggregate functions to Results<>

See the tests for examples of use. The same syntax could be applied to other things like sorting and querying.

@alazier 
because swift