Delen via


DataSourceVersionComparer Class

Provides the means to compare two data-source-specific version strings.

Inheritance Hierarchy

System.Object
  Microsoft.VisualStudio.Data.DataSourceVersionComparer

Namespace:  Microsoft.VisualStudio.Data
Assembly:  Microsoft.VisualStudio.Data (in Microsoft.VisualStudio.Data.dll)

Syntax

'Declaration
<GuidAttribute("38AFC6FE-E26A-4a33-ACF0-4E5D7F510746")> _
Public Class DataSourceVersionComparer _
    Implements IComparer(Of String)
[GuidAttribute("38AFC6FE-E26A-4a33-ACF0-4E5D7F510746")]
public class DataSourceVersionComparer : IComparer<string>
[GuidAttribute(L"38AFC6FE-E26A-4a33-ACF0-4E5D7F510746")]
public ref class DataSourceVersionComparer : IComparer<String^>
[<GuidAttribute("38AFC6FE-E26A-4a33-ACF0-4E5D7F510746")>]
type DataSourceVersionComparer =  
    class 
        interface IComparer<string>
    end
public class DataSourceVersionComparer implements IComparer<String>

The DataSourceVersionComparer type exposes the following members.

Constructors

  Name Description
Public method DataSourceVersionComparer() Class constructor. Instantiates a new instance of the DataSourceVersionComparer class.
Public method DataSourceVersionComparer(IComparer<String>) Class constructor. Instantiates a new instance of the DataSourceVersionComparer class using an IComparer object.

Top

Properties

  Name Description
Protected property Comparer Retrieves or sets the IComparer object with which to perform a comparison.

Top

Methods

  Name Description
Public method Compare Compares two data-source version strings and returns a value indicating whether one is less than, equal to, or greater than the other.
Public method Equals Determines whether the specified object is equal to the current object. (Inherited from Object.)
Protected method Finalize Allows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection. (Inherited from Object.)
Public method GetHashCode Serves as the default hash function. (Inherited from Object.)
Public method GetType Gets the Type of the current instance. (Inherited from Object.)
Protected method MemberwiseClone Creates a shallow copy of the current Object. (Inherited from Object.)
Public method ToString Returns a string that represents the current object. (Inherited from Object.)

Top

Fields

  Name Description
Public fieldStatic member Default Retrieves a default instance of this class that uses a default comparison mechanism that is both culture and case sensitive.

Top

Explicit Interface Implementations

  Name Description
Explicit interface implemetationPrivate method IComparer<String>.Compare Compares two data-source version strings and returns a value indicating whether one is less than, equal to, or greater than the other.

Top

Thread Safety

Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.

See Also

Reference

Microsoft.VisualStudio.Data Namespace

ICollection<T>

IComparer