ImmutableArrayExtensions::FirstOrDefault<T> Method (ImmutableArray<T>::Builder^)

 

Returns the first element in the collection, or the default value if the collection is empty.

Namespace:   System.Linq
Assembly:  System.Collections.Immutable (in System.Collections.Immutable.dll)

public:
generic<typename T>
[ExtensionAttribute]
static T FirstOrDefault(
	ImmutableArray<T>::Builder^ builder
)

Parameters

builder
Type: System.Collections.Immutable::ImmutableArray<T>::Builder^

The builder to retrieve an element from.

Return Value

Type: T

The first item in the list, if found; otherwise the default value for the item type.

Type Parameters

T

The type of item in the builder.

Return to top
Show: