Table of Contents

Method Max

Namespace
MongoDB.Driver.Linq
Assembly
MongoDB.Driver.dll

Max<TInput, TValue>(ISetWindowFieldsPartition<TInput>, Func<TInput, TValue>, SetWindowFieldsWindow)

Returns the maximum value.

public static TValue Max<TInput, TValue>(this ISetWindowFieldsPartition<TInput> partition, Func<TInput, TValue> selector, SetWindowFieldsWindow window = null)

Parameters

partition ISetWindowFieldsPartition<TInput>

The partition.

selector Func<TInput, TValue>

The selector that selects a value from the input document.

window SetWindowFieldsWindow

The window boundaries.

Returns

TValue

The maximum of the selected values.

Type Parameters

TInput

The type of the input documents in the partition.

TValue

The type of the selected values.