The static method, Collectors.summingLong() returns a Collector which uses a provided mapper function to convert each input element of type T to primitive long, and returns the sum of the resulting long values.
<T> Collector<T,?,Long> summingLong(ToLongFunction<? super T> mapper)