MemoryExtensions.SequenceCompareTo MemoryExtensions.SequenceCompareTo MemoryExtensions.SequenceCompareTo MemoryExtensions.SequenceCompareTo Method

定義

オーバーロード

SequenceCompareTo<T>(ReadOnlySpan<T>, ReadOnlySpan<T>) SequenceCompareTo<T>(ReadOnlySpan<T>, ReadOnlySpan<T>) SequenceCompareTo<T>(ReadOnlySpan<T>, ReadOnlySpan<T>) SequenceCompareTo<T>(ReadOnlySpan<T>, ReadOnlySpan<T>)

IComparable{T}.CompareTo(T) を使用して要素を比較することで、2 つの読み取り専用シーケンスの相対順序を決定します。Determines the relative order of two read-only sequences by comparing their elements using IComparable{T}.CompareTo(T).

SequenceCompareTo<T>(Span<T>, ReadOnlySpan<T>) SequenceCompareTo<T>(Span<T>, ReadOnlySpan<T>) SequenceCompareTo<T>(Span<T>, ReadOnlySpan<T>) SequenceCompareTo<T>(Span<T>, ReadOnlySpan<T>)

IComparable{T}.CompareTo(T) を使用して要素を比較することで、スパンと読み取り専用スパンの相対順序を決定します。Determines the relative order of a span and a read-only span by comparing the elements using IComparable{T}.CompareTo(T).

SequenceCompareTo<T>(ReadOnlySpan<T>, ReadOnlySpan<T>) SequenceCompareTo<T>(ReadOnlySpan<T>, ReadOnlySpan<T>) SequenceCompareTo<T>(ReadOnlySpan<T>, ReadOnlySpan<T>) SequenceCompareTo<T>(ReadOnlySpan<T>, ReadOnlySpan<T>)

IComparable{T}.CompareTo(T) を使用して要素を比較することで、2 つの読み取り専用シーケンスの相対順序を決定します。Determines the relative order of two read-only sequences by comparing their elements using IComparable{T}.CompareTo(T).

public:
generic <typename T>
 where T : IComparable<T>[System::Runtime::CompilerServices::Extension]
 static int SequenceCompareTo(ReadOnlySpan<T> span, ReadOnlySpan<T> other);
public static int SequenceCompareTo<T> (this ReadOnlySpan<T> span, ReadOnlySpan<T> other) where T : IComparable<T>;
static member SequenceCompareTo : ReadOnlySpan<'T (requires 'T :> IComparable<'T>)> * ReadOnlySpan<'T (requires 'T :> IComparable<'T>)> -> int (requires 'T :> IComparable<'T>)
<Extension()>
Public Function SequenceCompareTo(Of T As IComparable(Of T)) (span As ReadOnlySpan(Of T), other As ReadOnlySpan(Of T)) As Integer

型パラメーター

T

シーケンス内の要素の型。The type of elements in the sequence.

パラメーター

span
ReadOnlySpan<T> ReadOnlySpan<T> ReadOnlySpan<T> ReadOnlySpan<T>

比較する最初のシーケンス。The first sequence to compare.

other
ReadOnlySpan<T> ReadOnlySpan<T> ReadOnlySpan<T> ReadOnlySpan<T>

比較する 2 番目のシーケンス。The second sequence to compare.

戻り値

spanother の相対順序を示す符号付き整数。A signed integer that indicates the relative order of span and other:
- 0 未満の場合、spanother より順序が先になります。- If less than 0, span precedes than other.
- 0 の場合、spanother と等しくなります。- If 0, span equals other.
- 0 より大きい場合、spanother の後になります。- If greater than 0, span follows other.

SequenceCompareTo<T>(Span<T>, ReadOnlySpan<T>) SequenceCompareTo<T>(Span<T>, ReadOnlySpan<T>) SequenceCompareTo<T>(Span<T>, ReadOnlySpan<T>) SequenceCompareTo<T>(Span<T>, ReadOnlySpan<T>)

IComparable{T}.CompareTo(T) を使用して要素を比較することで、スパンと読み取り専用スパンの相対順序を決定します。Determines the relative order of a span and a read-only span by comparing the elements using IComparable{T}.CompareTo(T).

public:
generic <typename T>
 where T : IComparable<T>[System::Runtime::CompilerServices::Extension]
 static int SequenceCompareTo(Span<T> span, ReadOnlySpan<T> other);
public static int SequenceCompareTo<T> (this Span<T> span, ReadOnlySpan<T> other) where T : IComparable<T>;
static member SequenceCompareTo : Span<'T (requires 'T :> IComparable<'T>)> * ReadOnlySpan<'T (requires 'T :> IComparable<'T>)> -> int (requires 'T :> IComparable<'T>)
<Extension()>
Public Function SequenceCompareTo(Of T As IComparable(Of T)) (span As Span(Of T), other As ReadOnlySpan(Of T)) As Integer

型パラメーター

T

スパン内の要素の型。The type of elements in the span.

パラメーター

span
Span<T> Span<T> Span<T> Span<T>

比較対象とするスパン。The span to compare.

other
ReadOnlySpan<T> ReadOnlySpan<T> ReadOnlySpan<T> ReadOnlySpan<T>

比較する読み取り専用スパン。The read-only span to compare.

戻り値

spanother の相対順序を示す符号付き整数。A signed integer that indicates the relative order of span and other:
- 0 未満の場合、spanother より順序が先になります。- If less than 0, span precedes than other.
- 0 の場合、spanother と等しくなります。- If 0, span equals other.
- 0 より大きい場合、spanother の後になります。- If greater than 0, span follows other.

適用対象