Aerospike LINDPad Driver

AValueHelper..::..Cast<(Of <(<'TResult>)>)> Method

This method will cast each underlying value of an AValue element to TResult. To obtain values coerce into a type, use [Convert{TResult}(IEnumerable{AValue})].

Namespace:  Aerospike.Database.LINQPadDriver.Extensions
Assembly:  Aerospike.Database.LINQPadDriver (in Aerospike.Database.LINQPadDriver.dll)

Syntax


public static IEnumerable<TResult> Cast<TResult>(
	this IEnumerable<AValue> source
)

Type Parameters

TResult
The type each element matches

Parameters

source
Type: IEnumerable<(Of <(<'AValue>)>)>
A collection of AValue items

Return Value

A new collection of underlying items that have been cast to TResult

Exceptions


ExceptionCondition
ArgumentNullExceptionif source is null
InvalidCastExceptionIf an element cannot be cast to TResult