Click or drag to resize

CondensedCollectionExtensionsSumTSource Method (CondensedCollectionTSource, FuncTSource, Double)

[This is preliminary documentation and is subject to change.]

Computes the sum of a CondensedCollection of double values that are obtained by invoking a transform function on each element of the input sequence. Optimized for a CondensedCollection.

Namespace:  Condensed.Linq
Assembly:  Condensed (in Condensed.dll) Version: 0.1.0.0 (0.1.0.0)
Syntax
public static double Sum<TSource>(
	this CondensedCollection<TSource> source,
	Func<TSource, double> selector
)

Parameters

source
Type: CondensedCondensedCollectionTSource
A CondensedCollection of values to calculate the sum of.
selector
Type: SystemFuncTSource, Double
A transform function to apply to each element.

Type Parameters

TSource
The type of the elements of source.

Return Value

Type: Double
The sum of the sequence of values.

Usage Note

In Visual Basic and C#, you can call this method as an instance method on any object of type CondensedCollectionTSource. When you use instance method syntax to call this method, omit the first parameter. For more information, see Extension Methods (Visual Basic) or Extension Methods (C# Programming Guide).
Exceptions
ExceptionCondition
ArgumentNullExceptionsource or selector is null
Remarks
See Also