MemoryExtensions.SequenceCompareTo メソッド

定義

オーバーロード

名前 説明
SequenceCompareTo<T>(ReadOnlySpan<T>, ReadOnlySpan<T>)

IComparable{T} を使用して要素を比較することで、2 つの読み取り専用シーケンスの相対順序を決定します。CompareTo(T)。

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

IComparable{T} を使用して要素を比較することで、スパンと読み取り専用スパンの相対順序を決定します。CompareTo(T)。

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

IComparable{T} を使用して要素を比較することによって、比較するシーケンスの相対順序を決定します。CompareTo(T)。

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

ソース:
MemoryExtensions.cs
ソース:
MemoryExtensions.cs
ソース:
MemoryExtensions.cs
ソース:
MemoryExtensions.cs
ソース:
MemoryExtensions.cs

IComparable{T} を使用して要素を比較することで、2 つの読み取り専用シーケンスの相対順序を決定します。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

シーケンス内の要素の型。

パラメーター

span
ReadOnlySpan<T>

比較する最初のシーケンス。

other
ReadOnlySpan<T>

比較する 2 番目のシーケンス。

返品

spanotherの相対順序を示す符号付き整数。
- 0 未満の場合、 spanotherより前にあります。
- 0 の場合、 spanotherと等しくなります。
- 0 より大きい場合、 spanotherに従います。

適用対象

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

ソース:
MemoryExtensions.cs
ソース:
MemoryExtensions.cs
ソース:
MemoryExtensions.cs
ソース:
MemoryExtensions.cs
ソース:
MemoryExtensions.cs

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);
[System.Runtime.CompilerServices.OverloadResolutionPriority(-1)]
public static int SequenceCompareTo<T>(this Span<T> span, ReadOnlySpan<T> other) where T : IComparable<T>;
public static int SequenceCompareTo<T>(this Span<T> span, ReadOnlySpan<T> other) where T : IComparable<T>;
[<System.Runtime.CompilerServices.OverloadResolutionPriority(-1)>]
static member SequenceCompareTo : Span<'T (requires 'T :> IComparable<'T>)> * ReadOnlySpan<'T (requires 'T :> IComparable<'T>)> -> int (requires '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

スパン内の要素の型。

パラメーター

span
Span<T>

比較するスパン。

other
ReadOnlySpan<T>

比較する読み取り専用スパン。

返品

spanotherの相対順序を示す符号付き整数。
- 0 未満の場合、 spanotherより前にあります。
- 0 の場合、 spanotherと等しくなります。
- 0 より大きい場合、 spanotherに従います。

属性

適用対象

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

ソース:
MemoryExtensions.cs
ソース:
MemoryExtensions.cs

IComparable{T} を使用して要素を比較することによって、比較するシーケンスの相対順序を決定します。CompareTo(T)。

public static int SequenceCompareTo<T>(this ReadOnlySpan<T> span, ReadOnlySpan<T> other, System.Collections.Generic.IComparer<T>? comparer = default);
static member SequenceCompareTo : ReadOnlySpan<'T> * ReadOnlySpan<'T> * System.Collections.Generic.IComparer<'T> -> int
<Extension()>
Public Function SequenceCompareTo(Of T) (span As ReadOnlySpan(Of T), other As ReadOnlySpan(Of T), Optional comparer As IComparer(Of T) = Nothing) As Integer

型パラメーター

T

パラメーター

comparer
IComparer<T>

返品

適用対象