|Constructor and Description|
Creates a new group command.
|Modifier and Type||Method and Description|
Turns this group command into the DBObject format of the command.
public GroupCommand(DBCollection collection, DBObject keys, DBObject condition, DBObject initial, String reduce, String finalize)
collection- the collection from which to perform the group by operation.
keys- the field or fields to group.
condition- optional - a filter to determine which documents in the collection to process.
initial- the initial state of the aggregation result document.
public DBObject toDBObject()