EventDescriptorCollection.Sort Método

Definição

Classifica os membros deste EventDescriptorCollection.Sorts the members of this EventDescriptorCollection.

Sobrecargas

Sort(String[], IComparer)

Classifica os membros deste EventDescriptorCollection, dada uma ordem de classificação especificada e um IComparer.Sorts the members of this EventDescriptorCollection, given a specified sort order and an IComparer.

Sort(String[])

Classifica os membros deste EventDescriptorCollection, dada uma ordem de classificação especificada.Sorts the members of this EventDescriptorCollection, given a specified sort order.

Sort()

Classifica os membros deste EventDescriptorCollection, usando a classificação padrão para esta coleção, que é geralmente em ordem alfabética.Sorts the members of this EventDescriptorCollection, using the default sort for this collection, which is usually alphabetical.

Sort(IComparer)

Classifica os membros deste EventDescriptorCollection usando o IComparerespecificado.Sorts the members of this EventDescriptorCollection, using the specified IComparer.

Sort(String[], IComparer)

Classifica os membros deste EventDescriptorCollection, dada uma ordem de classificação especificada e um IComparer.Sorts the members of this EventDescriptorCollection, given a specified sort order and an IComparer.

public:
 virtual System::ComponentModel::EventDescriptorCollection ^ Sort(cli::array <System::String ^> ^ names, System::Collections::IComparer ^ comparer);
public virtual System.ComponentModel.EventDescriptorCollection Sort (string[] names, System.Collections.IComparer comparer);
abstract member Sort : string[] * System.Collections.IComparer -> System.ComponentModel.EventDescriptorCollection
override this.Sort : string[] * System.Collections.IComparer -> System.ComponentModel.EventDescriptorCollection
Public Overridable Function Sort (names As String(), comparer As IComparer) As EventDescriptorCollection

Parâmetros

names
String[]

Uma matriz de cadeias de caracteres que descreve a ordem de classificação dos objetos EventDescriptor na coleção.An array of strings describing the order in which to sort the EventDescriptor objects in the collection.

comparer
IComparer

Um IComparer a ser usado para classificar objetos EventDescriptor nesta coleção.An IComparer to use to sort the EventDescriptor objects in this collection.

Retornos

EventDescriptorCollection

O novo EventDescriptorCollection.The new EventDescriptorCollection.

Exemplos

O exemplo de código a seguir define a ordem de classificação para o Sort método.The following code example defines the sort order for the Sort method. Se o EventDescriptorCollection contiver quatro EventDescriptor objetos com os nomes A ,, B C e D , as propriedades de myNewColl serão classificadas na ordem D , B , A e C .If the EventDescriptorCollection contains four EventDescriptor objects with the names A, B, C, and D, the properties of myNewColl would be sorted in the order D, B, A, and C.

array<String^>^ temp0 = {"D","B"};
myNewColl = this->Sort( temp0 );
myNewColl = this.Sort(new string[]{"D", "B"});
myNewColl = Me.Sort(New String() {"D", "B"})

Comentários

A ordem de classificação especificada é aplicada primeiro, seguida pela classificação usando o especificado IComparer .The specified sort order is applied first, followed by the sort using the specified IComparer.

Observação

O HostProtectionAttribute atributo aplicado a essa classe tem o seguinte Resources valor de propriedade: Synchronization .The HostProtectionAttribute attribute applied to this class has the following Resources property value: Synchronization. HostProtectionAttribute não afeta aplicativos de área de trabalho (que são normalmente iniciados com o clique duplo em um ícone, a digitação de um comando ou a inserção de uma URL em um navegador).The HostProtectionAttribute does not affect desktop applications (which are typically started by double-clicking an icon, typing a command, or entering a URL in a browser). Para obter mais informações, consulte a HostProtectionAttribute classe ou os atributos de proteção de host e de programação de SQL Server.For more information, see the HostProtectionAttribute class or SQL Server Programming and Host Protection Attributes.

Confira também

Aplica-se a

Sort(String[])

Classifica os membros deste EventDescriptorCollection, dada uma ordem de classificação especificada.Sorts the members of this EventDescriptorCollection, given a specified sort order.

public:
 virtual System::ComponentModel::EventDescriptorCollection ^ Sort(cli::array <System::String ^> ^ names);
public virtual System.ComponentModel.EventDescriptorCollection Sort (string[] names);
abstract member Sort : string[] -> System.ComponentModel.EventDescriptorCollection
override this.Sort : string[] -> System.ComponentModel.EventDescriptorCollection
Public Overridable Function Sort (names As String()) As EventDescriptorCollection

Parâmetros

names
String[]

Uma matriz de cadeias de caracteres que descreve a ordem de classificação dos objetos EventDescriptor na coleção.An array of strings describing the order in which to sort the EventDescriptor objects in the collection.

Retornos

EventDescriptorCollection

O novo EventDescriptorCollection.The new EventDescriptorCollection.

Exemplos

O exemplo de código a seguir define a ordem de classificação para o Sort método.The following code example defines the sort order for the Sort method. Se o EventDescriptorCollection contiver quatro EventDescriptor objetos com os nomes A ,, B C e D , as propriedades de myNewColl serão classificadas na ordem D , B , A e C .If the EventDescriptorCollection contains four EventDescriptor objects with the names A, B, C, and D, the properties of myNewColl would be sorted in the order D, B, A, and C.

array<String^>^ temp0 = {"D","B"};
myNewColl = this->Sort( temp0 );
myNewColl = this.Sort(new string[]{"D", "B"});
myNewColl = Me.Sort(New String() {"D", "B"})

Comentários

A ordem especificada é aplicada primeiro, seguida pela classificação padrão para esta coleção, que é geralmente em ordem alfabética.The specified order is applied first, followed by the default sort for this collection, which is usually alphabetical.

Observação

O HostProtectionAttribute atributo aplicado a essa classe tem o seguinte Resources valor de propriedade: Synchronization .The HostProtectionAttribute attribute applied to this class has the following Resources property value: Synchronization. HostProtectionAttribute não afeta aplicativos de área de trabalho (que são normalmente iniciados com o clique duplo em um ícone, a digitação de um comando ou a inserção de uma URL em um navegador).The HostProtectionAttribute does not affect desktop applications (which are typically started by double-clicking an icon, typing a command, or entering a URL in a browser). Para obter mais informações, consulte a HostProtectionAttribute classe ou os atributos de proteção de host e de programação de SQL Server.For more information, see the HostProtectionAttribute class or SQL Server Programming and Host Protection Attributes.

Confira também

Aplica-se a

Sort()

Classifica os membros deste EventDescriptorCollection, usando a classificação padrão para esta coleção, que é geralmente em ordem alfabética.Sorts the members of this EventDescriptorCollection, using the default sort for this collection, which is usually alphabetical.

public:
 virtual System::ComponentModel::EventDescriptorCollection ^ Sort();
public virtual System.ComponentModel.EventDescriptorCollection Sort ();
abstract member Sort : unit -> System.ComponentModel.EventDescriptorCollection
override this.Sort : unit -> System.ComponentModel.EventDescriptorCollection
Public Overridable Function Sort () As EventDescriptorCollection

Retornos

EventDescriptorCollection

O novo EventDescriptorCollection.The new EventDescriptorCollection.

Exemplos

O exemplo de código a seguir define a ordem de classificação para o Sort método.The following code example defines the sort order for the Sort method. Se o EventDescriptorCollection contiver quatro EventDescriptor objetos com os nomes A ,, B C e D , as propriedades de myNewColl serão classificadas na ordem D , B , A e C .If the EventDescriptorCollection contains four EventDescriptor objects with the names A, B, C, and D, the properties of myNewColl would be sorted in the order D, B, A, and C.

array<String^>^ temp0 = {"D","B"};
myNewColl = this->Sort( temp0 );
myNewColl = this.Sort(new string[]{"D", "B"});
myNewColl = Me.Sort(New String() {"D", "B"})

Comentários

Observação

O HostProtectionAttribute atributo aplicado a essa classe tem o seguinte Resources valor de propriedade: Synchronization .The HostProtectionAttribute attribute applied to this class has the following Resources property value: Synchronization. HostProtectionAttribute não afeta aplicativos de área de trabalho (que são normalmente iniciados com o clique duplo em um ícone, a digitação de um comando ou a inserção de uma URL em um navegador).The HostProtectionAttribute does not affect desktop applications (which are typically started by double-clicking an icon, typing a command, or entering a URL in a browser). Para obter mais informações, consulte a HostProtectionAttribute classe ou os atributos de proteção de host e de programação de SQL Server.For more information, see the HostProtectionAttribute class or SQL Server Programming and Host Protection Attributes.

Aplica-se a

Sort(IComparer)

Classifica os membros deste EventDescriptorCollection usando o IComparerespecificado.Sorts the members of this EventDescriptorCollection, using the specified IComparer.

public:
 virtual System::ComponentModel::EventDescriptorCollection ^ Sort(System::Collections::IComparer ^ comparer);
public virtual System.ComponentModel.EventDescriptorCollection Sort (System.Collections.IComparer comparer);
abstract member Sort : System.Collections.IComparer -> System.ComponentModel.EventDescriptorCollection
override this.Sort : System.Collections.IComparer -> System.ComponentModel.EventDescriptorCollection
Public Overridable Function Sort (comparer As IComparer) As EventDescriptorCollection

Parâmetros

comparer
IComparer

Um IComparer a ser usado para classificar objetos EventDescriptor nesta coleção.An IComparer to use to sort the EventDescriptor objects in this collection.

Retornos

EventDescriptorCollection

O novo EventDescriptorCollection.The new EventDescriptorCollection.

Exemplos

O exemplo de código a seguir define a ordem de classificação para o Sort método.The following code example defines the sort order for the Sort method. Se o EventDescriptorCollection contiver quatro EventDescriptor objetos com os nomes A ,, B C e D , as propriedades de myNewColl serão classificadas na ordem D , B , A e C .If the EventDescriptorCollection contains four EventDescriptor objects with the names A, B, C, and D, the properties of myNewColl would be sorted in the order D, B, A, and C.

array<String^>^ temp0 = {"D","B"};
myNewColl = this->Sort( temp0 );
myNewColl = this.Sort(new string[]{"D", "B"});
myNewColl = Me.Sort(New String() {"D", "B"})

Comentários

O especificado IComparer é aplicado primeiro, seguido pela classificação padrão para essa coleção, que normalmente é alfabética.The specified IComparer is applied first, followed by the default sort for this collection, which is usually alphabetical.

Observação

O HostProtectionAttribute atributo aplicado a essa classe tem o seguinte Resources valor de propriedade: Synchronization .The HostProtectionAttribute attribute applied to this class has the following Resources property value: Synchronization. HostProtectionAttribute não afeta aplicativos de área de trabalho (que são normalmente iniciados com o clique duplo em um ícone, a digitação de um comando ou a inserção de uma URL em um navegador).The HostProtectionAttribute does not affect desktop applications (which are typically started by double-clicking an icon, typing a command, or entering a URL in a browser). Para obter mais informações, consulte a HostProtectionAttribute classe ou os atributos de proteção de host e de programação de SQL Server.For more information, see the HostProtectionAttribute class or SQL Server Programming and Host Protection Attributes.

Confira também

Aplica-se a