Collation.GetSortKey MethodCollation.GetSortKey MethodCollation::GetSortKey Method

Gets the sort key for the specified stringStringString as a byte array under this collation.

Syntax

Public MustOverride Function GetSortKey( _
    value As String _
) As Byte[]
public abstract byte[] GetSortKey(
    string value
)
public:
virtual array<byte> GetSortKey(
    String^ value
) abstract
 

Return Value

Type: System.Byte[]System.Byte()array<System::Byte>^

A byte array representing all strings equal to value.

Exceptions

ExceptionCondition
ArgumentNullExceptionArgumentNullExceptionArgumentNullExceptionvalue is null a null reference (Nothing in Visual Basic) nullptr.

Remarks

Currently the sort keys returned are only used by XmlPrime to compare equality, so there is no requirement other than that they uniquely identify the string returned. In the future however we intend to use this method for performing sorting operations, in which case the sort keys returned may need to be valid Unicode sort keys.