CosmosLinqExtensions.SumAsync Method

Definition

Overloads

SumAsync(IQueryable<Single>, CancellationToken)

Computes the sum of a sequence of Single values.

SumAsync(IQueryable<Nullable<Single>>, CancellationToken)

Computes the sum of a sequence of Nullable<T> values.

SumAsync(IQueryable<Nullable<Int64>>, CancellationToken)

Computes the sum of a sequence of Nullable<T> values.

SumAsync(IQueryable<Nullable<Int32>>, CancellationToken)

Computes the sum of a sequence of Nullable<T> values.

SumAsync(IQueryable<Nullable<Double>>, CancellationToken)

Computes the sum of a sequence of Nullable<T> values.

SumAsync(IQueryable<Int64>, CancellationToken)

Computes the sum of a sequence of Int64 values.

SumAsync(IQueryable<Int32>, CancellationToken)

Computes the sum of a sequence of Int32 values.

SumAsync(IQueryable<Double>, CancellationToken)

Computes the sum of a sequence of Double values.

SumAsync(IQueryable<Decimal>, CancellationToken)

Computes the sum of a sequence of Decimal values.

SumAsync(IQueryable<Nullable<Decimal>>, CancellationToken)

Computes the sum of a sequence of Nullable<T> values.

SumAsync(IQueryable<Single>, CancellationToken)

Source:
CosmosLinqExtensions.cs

Computes the sum of a sequence of Single values.

public static System.Threading.Tasks.Task<Microsoft.Azure.Cosmos.Response<float>> SumAsync (this System.Linq.IQueryable<float> source, System.Threading.CancellationToken cancellationToken = default);
static member SumAsync : System.Linq.IQueryable<single> * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Microsoft.Azure.Cosmos.Response<single>>
<Extension()>
Public Function SumAsync (source As IQueryable(Of Single), Optional cancellationToken As CancellationToken = Nothing) As Task(Of Response(Of Single))

Parameters

source
IQueryable<Single>

A sequence of values to calculate the average of.

cancellationToken
CancellationToken

The cancellation token.

Returns

The average value in the sequence.

Applies to

SumAsync(IQueryable<Nullable<Single>>, CancellationToken)

Source:
CosmosLinqExtensions.cs

Computes the sum of a sequence of Nullable<T> values.

public static System.Threading.Tasks.Task<Microsoft.Azure.Cosmos.Response<float?>> SumAsync (this System.Linq.IQueryable<float?> source, System.Threading.CancellationToken cancellationToken = default);
static member SumAsync : System.Linq.IQueryable<Nullable<single>> * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Microsoft.Azure.Cosmos.Response<Nullable<single>>>
<Extension()>
Public Function SumAsync (source As IQueryable(Of Nullable(Of Single)), Optional cancellationToken As CancellationToken = Nothing) As Task(Of Response(Of Nullable(Of Single)))

Parameters

source
IQueryable<Nullable<Single>>

A sequence of values to calculate the average of.

cancellationToken
CancellationToken

The cancellation token.

Returns

The average value in the sequence.

Applies to

SumAsync(IQueryable<Nullable<Int64>>, CancellationToken)

Source:
CosmosLinqExtensions.cs

Computes the sum of a sequence of Nullable<T> values.

public static System.Threading.Tasks.Task<Microsoft.Azure.Cosmos.Response<long?>> SumAsync (this System.Linq.IQueryable<long?> source, System.Threading.CancellationToken cancellationToken = default);
static member SumAsync : System.Linq.IQueryable<Nullable<int64>> * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Microsoft.Azure.Cosmos.Response<Nullable<int64>>>
<Extension()>
Public Function SumAsync (source As IQueryable(Of Nullable(Of Long)), Optional cancellationToken As CancellationToken = Nothing) As Task(Of Response(Of Nullable(Of Long)))

Parameters

source
IQueryable<Nullable<Int64>>

A sequence of values to calculate the average of.

cancellationToken
CancellationToken

The cancellation token.

Returns

The average value in the sequence.

Applies to

SumAsync(IQueryable<Nullable<Int32>>, CancellationToken)

Source:
CosmosLinqExtensions.cs

Computes the sum of a sequence of Nullable<T> values.

public static System.Threading.Tasks.Task<Microsoft.Azure.Cosmos.Response<int?>> SumAsync (this System.Linq.IQueryable<int?> source, System.Threading.CancellationToken cancellationToken = default);
static member SumAsync : System.Linq.IQueryable<Nullable<int>> * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Microsoft.Azure.Cosmos.Response<Nullable<int>>>
<Extension()>
Public Function SumAsync (source As IQueryable(Of Nullable(Of Integer)), Optional cancellationToken As CancellationToken = Nothing) As Task(Of Response(Of Nullable(Of Integer)))

Parameters

source
IQueryable<Nullable<Int32>>

A sequence of values to calculate the average of.

cancellationToken
CancellationToken

The cancellation token.

Returns

The average value in the sequence.

Applies to

SumAsync(IQueryable<Nullable<Double>>, CancellationToken)

Source:
CosmosLinqExtensions.cs

Computes the sum of a sequence of Nullable<T> values.

public static System.Threading.Tasks.Task<Microsoft.Azure.Cosmos.Response<double?>> SumAsync (this System.Linq.IQueryable<double?> source, System.Threading.CancellationToken cancellationToken = default);
static member SumAsync : System.Linq.IQueryable<Nullable<double>> * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Microsoft.Azure.Cosmos.Response<Nullable<double>>>
<Extension()>
Public Function SumAsync (source As IQueryable(Of Nullable(Of Double)), Optional cancellationToken As CancellationToken = Nothing) As Task(Of Response(Of Nullable(Of Double)))

Parameters

source
IQueryable<Nullable<Double>>

A sequence of values to calculate the average of.

cancellationToken
CancellationToken

The cancellation token.

Returns

The average value in the sequence.

Applies to

SumAsync(IQueryable<Int64>, CancellationToken)

Source:
CosmosLinqExtensions.cs

Computes the sum of a sequence of Int64 values.

public static System.Threading.Tasks.Task<Microsoft.Azure.Cosmos.Response<long>> SumAsync (this System.Linq.IQueryable<long> source, System.Threading.CancellationToken cancellationToken = default);
static member SumAsync : System.Linq.IQueryable<int64> * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Microsoft.Azure.Cosmos.Response<int64>>
<Extension()>
Public Function SumAsync (source As IQueryable(Of Long), Optional cancellationToken As CancellationToken = Nothing) As Task(Of Response(Of Long))

Parameters

source
IQueryable<Int64>

A sequence of values to calculate the average of.

cancellationToken
CancellationToken

The cancellation token.

Returns

The average value in the sequence.

Applies to

SumAsync(IQueryable<Int32>, CancellationToken)

Source:
CosmosLinqExtensions.cs

Computes the sum of a sequence of Int32 values.

public static System.Threading.Tasks.Task<Microsoft.Azure.Cosmos.Response<int>> SumAsync (this System.Linq.IQueryable<int> source, System.Threading.CancellationToken cancellationToken = default);
static member SumAsync : System.Linq.IQueryable<int> * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Microsoft.Azure.Cosmos.Response<int>>
<Extension()>
Public Function SumAsync (source As IQueryable(Of Integer), Optional cancellationToken As CancellationToken = Nothing) As Task(Of Response(Of Integer))

Parameters

source
IQueryable<Int32>

A sequence of values to calculate the average of.

cancellationToken
CancellationToken

The cancellation token.

Returns

The average value in the sequence.

Applies to

SumAsync(IQueryable<Double>, CancellationToken)

Source:
CosmosLinqExtensions.cs

Computes the sum of a sequence of Double values.

public static System.Threading.Tasks.Task<Microsoft.Azure.Cosmos.Response<double>> SumAsync (this System.Linq.IQueryable<double> source, System.Threading.CancellationToken cancellationToken = default);
static member SumAsync : System.Linq.IQueryable<double> * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Microsoft.Azure.Cosmos.Response<double>>
<Extension()>
Public Function SumAsync (source As IQueryable(Of Double), Optional cancellationToken As CancellationToken = Nothing) As Task(Of Response(Of Double))

Parameters

source
IQueryable<Double>

A sequence of values to calculate the average of.

cancellationToken
CancellationToken

The cancellation token.

Returns

The average value in the sequence.

Applies to

SumAsync(IQueryable<Decimal>, CancellationToken)

Source:
CosmosLinqExtensions.cs

Computes the sum of a sequence of Decimal values.

public static System.Threading.Tasks.Task<Microsoft.Azure.Cosmos.Response<decimal>> SumAsync (this System.Linq.IQueryable<decimal> source, System.Threading.CancellationToken cancellationToken = default);
static member SumAsync : System.Linq.IQueryable<decimal> * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Microsoft.Azure.Cosmos.Response<decimal>>
<Extension()>
Public Function SumAsync (source As IQueryable(Of Decimal), Optional cancellationToken As CancellationToken = Nothing) As Task(Of Response(Of Decimal))

Parameters

source
IQueryable<Decimal>

A sequence of values to calculate the average of.

cancellationToken
CancellationToken

The cancellation token.

Returns

The average value in the sequence.

Applies to

SumAsync(IQueryable<Nullable<Decimal>>, CancellationToken)

Source:
CosmosLinqExtensions.cs

Computes the sum of a sequence of Nullable<T> values.

public static System.Threading.Tasks.Task<Microsoft.Azure.Cosmos.Response<decimal?>> SumAsync (this System.Linq.IQueryable<decimal?> source, System.Threading.CancellationToken cancellationToken = default);
static member SumAsync : System.Linq.IQueryable<Nullable<decimal>> * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Microsoft.Azure.Cosmos.Response<Nullable<decimal>>>
<Extension()>
Public Function SumAsync (source As IQueryable(Of Nullable(Of Decimal)), Optional cancellationToken As CancellationToken = Nothing) As Task(Of Response(Of Nullable(Of Decimal)))

Parameters

source
IQueryable<Nullable<Decimal>>

A sequence of values to calculate the average of.

cancellationToken
CancellationToken

The cancellation token.

Returns

The average value in the sequence.

Applies to