Bagikan melalui


BuffersExtensions.PositionOf<T>(ReadOnlySequence<T>, T) Metode

Definisi

Mengembalikan posisi kemunculan item pertama dalam ReadOnlySequence<T>.

public:
generic <typename T>
 where T : IEquatable<T>[System::Runtime::CompilerServices::Extension]
 static Nullable<SequencePosition> PositionOf(System::Buffers::ReadOnlySequence<T> % source, T value);
public static SequencePosition? PositionOf<T> (this in System.Buffers.ReadOnlySequence<T> source, T value) where T : IEquatable<T>;
static member PositionOf : ReadOnlySequence * 'T -> Nullable<SequencePosition> (requires 'T :> IEquatable<'T>)
<Extension()>
Public Function PositionOf(Of T As IEquatable(Of T)) (ByRef source As ReadOnlySequence(Of T), value As T) As Nullable(Of SequencePosition)

Jenis parameter

T

Jenis item di ReadOnlySequence<T>.

Parameter

value
T

Item yang akan ditemukan di ReadOnlySequence<T>.

Mengembalikan

Objek yang metodenya GetInteger() mengembalikan posisi kemunculan itempertama , atau objek yang propertinya Nullable<SequencePosition>.HasValue adalah false .

Berlaku untuk