sum method

AggregateField sum(
  1. JSAny field
)

Create an AggregateField object that can be used to compute the sum of a specified field over a range of documents in the result set of a query. @param field Specifies the field to sum across the result set.

Implementation

external AggregateField sum(JSAny field);