ImmutableSortedSet.Create Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Overloads
Create<T>() |
Creates an empty immutable sorted set. |
Create<T>(IComparer<T>) |
Creates an empty immutable sorted set that uses the specified comparer. |
Create<T>(ReadOnlySpan<T>) |
Creates a new immutable sorted set that contains the specified array of items. |
Create<T>(T) |
Creates a new immutable sorted set that contains the specified item. |
Create<T>(T[]) |
Creates a new immutable sorted set that contains the specified array of items. |
Create<T>(IComparer<T>, ReadOnlySpan<T>) |
Creates a new immutable collection prefilled with the specified items. |
Create<T>(IComparer<T>, T) |
Creates a new immutable sorted set that contains the specified item and uses the specified comparer. |
Create<T>(IComparer<T>, T[]) |
Creates a new immutable sorted set that contains the specified array of items and uses the specified comparer. |
Create<T>()
- Source:
- ImmutableSortedSet.cs
- Source:
- ImmutableSortedSet.cs
- Source:
- ImmutableSortedSet.cs
Creates an empty immutable sorted set.
public:
generic <typename T>
static System::Collections::Immutable::ImmutableSortedSet<T> ^ Create();
public static System.Collections.Immutable.ImmutableSortedSet<T> Create<T> ();
static member Create : unit -> System.Collections.Immutable.ImmutableSortedSet<'T>
Public Function Create(Of T) () As ImmutableSortedSet(Of T)
Type Parameters
- T
The type of items to be stored in the immutable set.
Returns
An empty immutable sorted set.
Applies to
Create<T>(IComparer<T>)
- Source:
- ImmutableSortedSet.cs
- Source:
- ImmutableSortedSet.cs
- Source:
- ImmutableSortedSet.cs
Creates an empty immutable sorted set that uses the specified comparer.
public:
generic <typename T>
static System::Collections::Immutable::ImmutableSortedSet<T> ^ Create(System::Collections::Generic::IComparer<T> ^ comparer);
public static System.Collections.Immutable.ImmutableSortedSet<T> Create<T> (System.Collections.Generic.IComparer<T> comparer);
public static System.Collections.Immutable.ImmutableSortedSet<T> Create<T> (System.Collections.Generic.IComparer<T>? comparer);
static member Create : System.Collections.Generic.IComparer<'T> -> System.Collections.Immutable.ImmutableSortedSet<'T>
Public Function Create(Of T) (comparer As IComparer(Of T)) As ImmutableSortedSet(Of T)
Type Parameters
- T
The type of items in the immutable set.
Parameters
- comparer
- IComparer<T>
The implementation to use when comparing items in the set.
Returns
An empty immutable set.
Applies to
Create<T>(ReadOnlySpan<T>)
- Source:
- ImmutableSortedSet.cs
- Source:
- ImmutableSortedSet.cs
Creates a new immutable sorted set that contains the specified array of items.
public:
generic <typename T>
static System::Collections::Immutable::ImmutableSortedSet<T> ^ Create(ReadOnlySpan<T> items);
public static System.Collections.Immutable.ImmutableSortedSet<T> Create<T> (ReadOnlySpan<T> items);
public static System.Collections.Immutable.ImmutableSortedSet<T> Create<T> (scoped ReadOnlySpan<T> items);
static member Create : ReadOnlySpan<'T> -> System.Collections.Immutable.ImmutableSortedSet<'T>
Public Function Create(Of T) (items As ReadOnlySpan(Of T)) As ImmutableSortedSet(Of T)
Type Parameters
- T
The type of items in the immutable set.
Parameters
- items
- ReadOnlySpan<T>
A span that contains the items to prepopulate the set with.
Returns
A new immutable set that contains the specified items.
Applies to
Create<T>(T)
- Source:
- ImmutableSortedSet.cs
- Source:
- ImmutableSortedSet.cs
- Source:
- ImmutableSortedSet.cs
Creates a new immutable sorted set that contains the specified item.
public:
generic <typename T>
static System::Collections::Immutable::ImmutableSortedSet<T> ^ Create(T item);
public static System.Collections.Immutable.ImmutableSortedSet<T> Create<T> (T item);
static member Create : 'T -> System.Collections.Immutable.ImmutableSortedSet<'T>
Public Function Create(Of T) (item As T) As ImmutableSortedSet(Of T)
Type Parameters
- T
The type of items in the immutable set.
Parameters
- item
- T
The item to prepopulate the set with.
Returns
A new immutable set that contains the specified item.
Applies to
Create<T>(T[])
- Source:
- ImmutableSortedSet.cs
- Source:
- ImmutableSortedSet.cs
- Source:
- ImmutableSortedSet.cs
Creates a new immutable sorted set that contains the specified array of items.
public:
generic <typename T>
static System::Collections::Immutable::ImmutableSortedSet<T> ^ Create(... cli::array <T> ^ items);
public static System.Collections.Immutable.ImmutableSortedSet<T> Create<T> (params T[] items);
static member Create : 'T[] -> System.Collections.Immutable.ImmutableSortedSet<'T>
Public Function Create(Of T) (ParamArray items As T()) As ImmutableSortedSet(Of T)
Type Parameters
- T
The type of items in the immutable set.
Parameters
- items
- T[]
An array that contains the items to prepopulate the set with.
Returns
A new immutable set that contains the specified items.
Applies to
Create<T>(IComparer<T>, ReadOnlySpan<T>)
- Source:
- ImmutableSortedSet.cs
- Source:
- ImmutableSortedSet.cs
Creates a new immutable collection prefilled with the specified items.
public:
generic <typename T>
static System::Collections::Immutable::ImmutableSortedSet<T> ^ Create(System::Collections::Generic::IComparer<T> ^ comparer, ReadOnlySpan<T> items);
public static System.Collections.Immutable.ImmutableSortedSet<T> Create<T> (System.Collections.Generic.IComparer<T>? comparer, ReadOnlySpan<T> items);
public static System.Collections.Immutable.ImmutableSortedSet<T> Create<T> (System.Collections.Generic.IComparer<T>? comparer, scoped ReadOnlySpan<T> items);
static member Create : System.Collections.Generic.IComparer<'T> * ReadOnlySpan<'T> -> System.Collections.Immutable.ImmutableSortedSet<'T>
Public Function Create(Of T) (comparer As IComparer(Of T), items As ReadOnlySpan(Of T)) As ImmutableSortedSet(Of T)
Type Parameters
- T
The type of items stored by the collection.
Parameters
- comparer
- IComparer<T>
The comparer.
- items
- ReadOnlySpan<T>
The items to prepopulate.
Returns
The new immutable collection.
Applies to
Create<T>(IComparer<T>, T)
- Source:
- ImmutableSortedSet.cs
- Source:
- ImmutableSortedSet.cs
- Source:
- ImmutableSortedSet.cs
Creates a new immutable sorted set that contains the specified item and uses the specified comparer.
public:
generic <typename T>
static System::Collections::Immutable::ImmutableSortedSet<T> ^ Create(System::Collections::Generic::IComparer<T> ^ comparer, T item);
public static System.Collections.Immutable.ImmutableSortedSet<T> Create<T> (System.Collections.Generic.IComparer<T> comparer, T item);
public static System.Collections.Immutable.ImmutableSortedSet<T> Create<T> (System.Collections.Generic.IComparer<T>? comparer, T item);
static member Create : System.Collections.Generic.IComparer<'T> * 'T -> System.Collections.Immutable.ImmutableSortedSet<'T>
Public Function Create(Of T) (comparer As IComparer(Of T), item As T) As ImmutableSortedSet(Of T)
Type Parameters
- T
The type of items stored in the immutable set.
Parameters
- comparer
- IComparer<T>
The implementation to use when comparing items in the set.
- item
- T
The item to prepopulate the set with.
Returns
A new immutable set that contains the specified item.
Applies to
Create<T>(IComparer<T>, T[])
- Source:
- ImmutableSortedSet.cs
- Source:
- ImmutableSortedSet.cs
- Source:
- ImmutableSortedSet.cs
Creates a new immutable sorted set that contains the specified array of items and uses the specified comparer.
public:
generic <typename T>
static System::Collections::Immutable::ImmutableSortedSet<T> ^ Create(System::Collections::Generic::IComparer<T> ^ comparer, ... cli::array <T> ^ items);
public static System.Collections.Immutable.ImmutableSortedSet<T> Create<T> (System.Collections.Generic.IComparer<T> comparer, params T[] items);
public static System.Collections.Immutable.ImmutableSortedSet<T> Create<T> (System.Collections.Generic.IComparer<T>? comparer, params T[] items);
static member Create : System.Collections.Generic.IComparer<'T> * 'T[] -> System.Collections.Immutable.ImmutableSortedSet<'T>
Public Function Create(Of T) (comparer As IComparer(Of T), ParamArray items As T()) As ImmutableSortedSet(Of T)
Type Parameters
- T
The type of items in the immutable set.
Parameters
- comparer
- IComparer<T>
The implementation to use when comparing items in the set.
- items
- T[]
An array that contains the items to prepopulate the set with.
Returns
A new immutable set that contains the specified items.