PropertyDescriptorCollection.InternalSort Method

Definition

Sorts the members of this collection.

Overloads

InternalSort(IComparer)

Sorts the members of this collection, using the specified IComparer.

InternalSort(String[])

Sorts the members of this collection. The specified order is applied first, followed by the default sort for this collection, which is usually alphabetical.

InternalSort(IComparer)

Source:
PropertyDescriptorCollection.cs
Source:
PropertyDescriptorCollection.cs
Source:
PropertyDescriptorCollection.cs

Sorts the members of this collection, using the specified IComparer.

C#
protected void InternalSort(System.Collections.IComparer? sorter);
C#
protected void InternalSort(System.Collections.IComparer sorter);

Parameters

sorter
IComparer

A comparer to use to sort the PropertyDescriptor objects in this collection.

See also

Applies to

.NET 10 and other versions
Product Versions
.NET Core 1.0, Core 1.1, Core 2.0, Core 2.1, Core 2.2, Core 3.0, Core 3.1, 5, 6, 7, 8, 9, 10
.NET Framework 1.1, 2.0, 3.0, 3.5, 4.0, 4.5, 4.5.1, 4.5.2, 4.6, 4.6.1, 4.6.2, 4.7, 4.7.1, 4.7.2, 4.8, 4.8.1
.NET Standard 2.0, 2.1

InternalSort(String[])

Source:
PropertyDescriptorCollection.cs
Source:
PropertyDescriptorCollection.cs
Source:
PropertyDescriptorCollection.cs

Sorts the members of this collection. The specified order is applied first, followed by the default sort for this collection, which is usually alphabetical.

C#
protected void InternalSort(string[]? names);
C#
protected void InternalSort(string[] names);

Parameters

names
String[]

An array of strings describing the order in which to sort the PropertyDescriptor objects in this collection.

Examples

The following code example defines the sort order for the InternalSort method. If the PropertyDescriptorCollection contains four PropertyDescriptor objects with the names A, B, C, and D, the properties of myNewColl would be sorted in the order D, B, A, and C.

C#
this.InternalSort(new string[]{"D", "B"});

See also

Applies to

.NET 10 and other versions
Product Versions
.NET Core 1.0, Core 1.1, Core 2.0, Core 2.1, Core 2.2, Core 3.0, Core 3.1, 5, 6, 7, 8, 9, 10
.NET Framework 1.1, 2.0, 3.0, 3.5, 4.0, 4.5, 4.5.1, 4.5.2, 4.6, 4.6.1, 4.6.2, 4.7, 4.7.1, 4.7.2, 4.8, 4.8.1
.NET Standard 2.0, 2.1