Bewerken

Share via


FrozenSet.Create Method

Definition

Overloads

Create<T>(ReadOnlySpan<T>)

Creates a FrozenSet<T> with the specified values.

Create<T>(IEqualityComparer<T>, ReadOnlySpan<T>)

Creates a FrozenSet<T> with the specified values.

Create<T>(ReadOnlySpan<T>)

Source:
FrozenSet.cs

Creates a FrozenSet<T> with the specified values.

public:
generic <typename T>
 static System::Collections::Frozen::FrozenSet<T> ^ Create(ReadOnlySpan<T> source);
public static System.Collections.Frozen.FrozenSet<T> Create<T> (scoped ReadOnlySpan<T> source);
static member Create : ReadOnlySpan<'T> -> System.Collections.Frozen.FrozenSet<'T>
Public Function Create(Of T) (source As ReadOnlySpan(Of T)) As FrozenSet(Of T)

Type Parameters

T

The type of the values in the set.

Parameters

source
ReadOnlySpan<T>

The values to use to populate the set.

Returns

A frozen set.

Applies to

Create<T>(IEqualityComparer<T>, ReadOnlySpan<T>)

Source:
FrozenSet.cs

Creates a FrozenSet<T> with the specified values.

public:
generic <typename T>
 static System::Collections::Frozen::FrozenSet<T> ^ Create(System::Collections::Generic::IEqualityComparer<T> ^ equalityComparer, ReadOnlySpan<T> source);
public static System.Collections.Frozen.FrozenSet<T> Create<T> (System.Collections.Generic.IEqualityComparer<T>? equalityComparer, scoped ReadOnlySpan<T> source);
static member Create : System.Collections.Generic.IEqualityComparer<'T> * ReadOnlySpan<'T> -> System.Collections.Frozen.FrozenSet<'T>
Public Function Create(Of T) (equalityComparer As IEqualityComparer(Of T), source As ReadOnlySpan(Of T)) As FrozenSet(Of T)

Type Parameters

T

The type of the values in the set.

Parameters

equalityComparer
IEqualityComparer<T>

The comparer implementation to use to compare values for equality. If null, Default is used.

source
ReadOnlySpan<T>

The values to use to populate the set.

Returns

A frozen set.

Applies to