IComparer(String).Compare 方法

Compares two specified objects.

命名空间:  Microsoft.SqlServer.Management.Common
程序集:  Microsoft.SqlServer.ConnectionInfo(在 Microsoft.SqlServer.ConnectionInfo.dll 中)

语法

声明
Private Function Compare ( _
    x As String, _
    y As String _
) As Integer Implements IComparer(Of String).Compare
用法
Dim instance As ServerComparer
Dim x As String
Dim y As String
Dim returnValue As Integer

returnValue = CType(instance, IComparer(Of String)).Compare(x, _
    y)
int IComparer<string>.Compare(
    string x,
    string y
)
private:
virtual int Compare(
    String^ x, 
    String^ y
) sealed = IComparer<String^>::Compare
private abstract Compare : 
        x:string * 
        y:string -> int 
private override Compare : 
        x:string * 
        y:string -> int 
JScript 支持使用显式接口实现,但不支持声明新显式接口实现。

参数

返回值

类型:System. . :: . .Int32
A Int32 value.

实现

IComparer< (Of < ( <'T> ) > ) >. . :: . .Compare(T, T)