215 instantiations of ReadOnlySequence
http2cat (1)
IIS.FunctionalTests (1)
IIS.LongTests (1)
IIS.NewHandler.FunctionalTests (1)
IIS.NewShim.FunctionalTests (1)
IISExpress.FunctionalTests (1)
InMemory.FunctionalTests (4)
Microsoft.AspNetCore.Components.Forms (1)
Microsoft.AspNetCore.Components.Server (3)
Microsoft.AspNetCore.Components.Server.Tests (7)
Microsoft.AspNetCore.Components.Web (1)
Microsoft.AspNetCore.Http.Connections.Tests (10)
src\Shared\Buffers.Testing\ReadOnlySequenceFactory.cs (5)
31return new ReadOnlySequence<byte>(new byte[size + 20], 10, size);
38return new ReadOnlySequence<byte>(startSegment, 10, data.Length);
53return new ReadOnlySequence<byte>(new Memory<byte>(startSegment, 10, data.Length));
68return new ReadOnlySequence<byte>(new CustomMemoryForTest<byte>(startSegment, 10, data.Length).Memory);
146return new ReadOnlySequence<byte>(first, 0, last, last.Memory.Length);
Microsoft.AspNetCore.HttpLogging (1)
Microsoft.AspNetCore.Mvc.TagHelpers.Test (1)
Microsoft.AspNetCore.OutputCaching (8)
OutputCacheEntryFormatter.cs (4)
49await bufferStore.SetAsync(key, new(buffer.GetCommittedMemory()), CopyToLeasedMemory(tags, out var lease), duration, cancellationToken);
319result.SetBody(new ReadOnlySequence<byte>(ReadSegment(ref reader)), recycleBuffers: false); // we're reusing the live payload buffers
329result.SetBody(new ReadOnlySequence<byte>(first, 0, last, last.Length), recycleBuffers: false); // we're reusing the live payload buffers
369result.SetBody(new(reader.ReadBytesMemory(payloadLength)), recycleBuffers: false); // we're reusing the live payload buffers
Microsoft.AspNetCore.OutputCaching.StackExchangeRedis (1)
Microsoft.AspNetCore.Server.HttpSys.FunctionalTests (1)
Microsoft.AspNetCore.Server.Kestrel.Core (2)
Microsoft.AspNetCore.Server.Kestrel.Core.Tests (50)
src\Shared\Buffers.Testing\ReadOnlySequenceFactory.cs (5)
31return new ReadOnlySequence<byte>(new byte[size + 20], 10, size);
38return new ReadOnlySequence<byte>(startSegment, 10, data.Length);
53return new ReadOnlySequence<byte>(new Memory<byte>(startSegment, 10, data.Length));
68return new ReadOnlySequence<byte>(new CustomMemoryForTest<byte>(startSegment, 10, data.Length).Memory);
146return new ReadOnlySequence<byte>(first, 0, last, last.Memory.Length);
Microsoft.AspNetCore.Server.Kestrel.Microbenchmarks (3)
Microsoft.AspNetCore.Shared.Tests (6)
Microsoft.AspNetCore.SignalR.Common (1)
Microsoft.AspNetCore.SignalR.Common.Tests (57)
src\Shared\Buffers.Testing\ReadOnlySequenceFactory.cs (5)
31return new ReadOnlySequence<byte>(new byte[size + 20], 10, size);
38return new ReadOnlySequence<byte>(startSegment, 10, data.Length);
53return new ReadOnlySequence<byte>(new Memory<byte>(startSegment, 10, data.Length));
68return new ReadOnlySequence<byte>(new CustomMemoryForTest<byte>(startSegment, 10, data.Length).Memory);
146return new ReadOnlySequence<byte>(first, 0, last, last.Memory.Length);
Microsoft.AspNetCore.SignalR.Microbenchmarks (21)
src\Shared\Buffers.Testing\ReadOnlySequenceFactory.cs (5)
31return new ReadOnlySequence<byte>(new byte[size + 20], 10, size);
38return new ReadOnlySequence<byte>(startSegment, 10, data.Length);
53return new ReadOnlySequence<byte>(new Memory<byte>(startSegment, 10, data.Length));
68return new ReadOnlySequence<byte>(new CustomMemoryForTest<byte>(startSegment, 10, data.Length).Memory);
146return new ReadOnlySequence<byte>(first, 0, last, last.Memory.Length);
Microsoft.AspNetCore.SignalR.Protocols.NewtonsoftJson (1)
Microsoft.AspNetCore.SignalR.StackExchangeRedis (1)
Microsoft.AspNetCore.SignalR.StackExchangeRedis.Tests (2)
RedisProtocolTests.cs (2)
207new RedisCompletion("json", new ReadOnlySequence<byte>(Encoding.UTF8.GetBytes("{\"type\":3,\"invocationId\":\"1\",\"result\":1}"))),
221new RedisCompletion("messagepack", new ReadOnlySequence<byte>(new byte[] { 0x95, 0x03, 0x80, 0xa3, (byte)'x', (byte)'y', (byte)'z', 0x03, 0x2a })),
Microsoft.AspNetCore.WebUtilities.Microbenchmarks (6)
src\Shared\Buffers.Testing\ReadOnlySequenceFactory.cs (5)
31return new ReadOnlySequence<byte>(new byte[size + 20], 10, size);
38return new ReadOnlySequence<byte>(startSegment, 10, data.Length);
53return new ReadOnlySequence<byte>(new Memory<byte>(startSegment, 10, data.Length));
68return new ReadOnlySequence<byte>(new CustomMemoryForTest<byte>(startSegment, 10, data.Length).Memory);
146return new ReadOnlySequence<byte>(first, 0, last, last.Memory.Length);
Microsoft.AspNetCore.WebUtilities.Tests (8)
src\Shared\Buffers.Testing\ReadOnlySequenceFactory.cs (5)
31return new ReadOnlySequence<byte>(new byte[size + 20], 10, size);
38return new ReadOnlySequence<byte>(startSegment, 10, data.Length);
53return new ReadOnlySequence<byte>(new Memory<byte>(startSegment, 10, data.Length));
68return new ReadOnlySequence<byte>(new CustomMemoryForTest<byte>(startSegment, 10, data.Length).Memory);
146return new ReadOnlySequence<byte>(first, 0, last, last.Memory.Length);
Microsoft.Extensions.Caching.Hybrid (2)
Microsoft.Extensions.Caching.Hybrid.Tests (4)
Microsoft.Extensions.Caching.StackExchangeRedis (2)
System.IO.Pipelines (2)
System.Memory (3)
985 references to ReadOnlySequence
Aspire.Dashboard (1)
Aspire.Hosting (1)
ClientSample (4)
http2cat (16)
IIS.FunctionalTests (16)
IIS.LongTests (16)
IIS.NewHandler.FunctionalTests (16)
IIS.NewShim.FunctionalTests (16)
IIS.ShadowCopy.Tests (13)
IISExpress.FunctionalTests (16)
InMemory.FunctionalTests (10)
Interop.FunctionalTests (2)
Microsoft.AspNetCore.Components.Forms (1)
Microsoft.AspNetCore.Components.Server (43)
Microsoft.AspNetCore.Components.Server.Tests (9)
Microsoft.AspNetCore.Components.Web (1)
Microsoft.AspNetCore.Grpc.JsonTranscoding.Tests (3)
Microsoft.AspNetCore.Http.Connections (12)
Microsoft.AspNetCore.Http.Connections.Client (8)
Microsoft.AspNetCore.Http.Connections.Tests (20)
Microsoft.AspNetCore.HttpLogging (2)
Microsoft.AspNetCore.Mvc.TagHelpers.Test (1)
Microsoft.AspNetCore.OutputCaching (10)
Microsoft.AspNetCore.OutputCaching.Microbenchmarks (4)
Microsoft.AspNetCore.OutputCaching.StackExchangeRedis (1)
Microsoft.AspNetCore.OutputCaching.Tests (10)
Microsoft.AspNetCore.ResponseCaching.Microbenchmarks (1)
Microsoft.AspNetCore.ResponseCaching.Tests (1)
Microsoft.AspNetCore.Server.HttpSys.FunctionalTests (16)
Microsoft.AspNetCore.Server.IIS (18)
Microsoft.AspNetCore.Server.Kestrel.Core (88)
Internal\Http\Http1ChunkedEncodingMessageBody.cs (10)
113var readableBuffer = result.Buffer;
202private bool Read(ReadOnlySequence<byte> readableBuffer, PipeWriter writableBuffer, out SequencePosition consumed, out SequencePosition examined)
291private void ParseChunkedPrefix(in ReadOnlySequence<byte> buffer, out SequencePosition consumed, out SequencePosition examined)
348private void ParseExtension(ReadOnlySequence<byte> buffer, out SequencePosition consumed, out SequencePosition examined)
369var suffixBuffer = buffer.Slice(extensionCursor);
400private void ReadChunkedData(in ReadOnlySequence<byte> buffer, PipeWriter writableBuffer, out SequencePosition consumed, out SequencePosition examined)
417private void ParseChunkedSuffix(in ReadOnlySequence<byte> buffer, out SequencePosition consumed, out SequencePosition examined)
427var suffixBuffer = buffer.Slice(0, 2);
445private void ParseChunkedTrailer(in ReadOnlySequence<byte> buffer, out SequencePosition consumed, out SequencePosition examined)
455var trailerBuffer = buffer.Slice(0, 2);
Internal\Http2\Http2Connection.cs (17)
321var buffer = result.Buffer;
335while (Http2FrameReader.TryReadFrame(ref buffer, _incomingFrame, _serverSettings.MaxFrameSize, out var framePayload))
554var readableBuffer = result.Buffer;
633private bool ParseHttp1x(ReadOnlySequence<byte> buffer, out HttpVersion httpVersion)
658private static bool IsPreface(in ReadOnlySequence<byte> buffer, out SequencePosition consumed, out SequencePosition examined)
665var preface = buffer.Slice(0, ClientPreface.Length);
677private Task ProcessFrameAsync<TContext>(IHttpApplication<TContext> application, in ReadOnlySequence<byte> payload) where TContext : notnull
704private Task ProcessDataFrameAsync(in ReadOnlySequence<byte> payload)
786private Task ProcessHeadersFrameAsync<TContext>(IHttpApplication<TContext> application, in ReadOnlySequence<byte> payload) where TContext : notnull
838var headersPayload = payload.Slice(0, _incomingFrame.HeadersPayloadLength); // Minus padding
871var headersPayload = payload.Slice(0, _incomingFrame.HeadersPayloadLength); // Minus padding
979private Task ProcessSettingsFrameAsync(in ReadOnlySequence<byte> payload)
1063private Task ProcessPingFrameAsync(in ReadOnlySequence<byte> payload)
1180private Task ProcessContinuationFrameAsync(in ReadOnlySequence<byte> payload)
1219private Task DecodeHeadersAsync(bool endHeaders, in ReadOnlySequence<byte> payload)
1246private Task DecodeTrailersAsync(bool endHeaders, in ReadOnlySequence<byte> payload)
1868var bufferSlice = readResult.Buffer.Slice(0, copyAmount);
Internal\Http2\Http2FrameWriter.cs (8)
193var buffer = readResult.Buffer;
563private ValueTask<FlushResult> WriteDataAndTrailersAsync(Http2Stream stream, in ReadOnlySequence<byte> data, bool writeHeaders, HttpResponseTrailers headers)
715private void WriteDataUnsynchronized(int streamId, in ReadOnlySequence<byte> data, long dataLength, bool endStream)
742void TrimAndWriteDataUnsynchronized(in ReadOnlySequence<byte> data, long dataLength, bool endStream)
750var remainingData = data;
753var currentData = remainingData.Slice(0, dataPayloadLength);
781private ValueTask<FlushResult> WriteDataAsync(Http2Stream stream, ReadOnlySequence<byte> data, long dataLength, bool endStream, bool writeHeaders)
957public ValueTask<FlushResult> WritePingAsync(Http2PingFrameFlags flags, in ReadOnlySequence<byte> payload)
Microsoft.AspNetCore.Server.Kestrel.Core.Tests (88)
Http1\Http1ConnectionTests.cs (21)
35var readableBuffer = (await _transport.Input.ReadAsync()).Buffer;
54var readableBuffer = (await _transport.Input.ReadAsync()).Buffer;
67var readableBuffer = (await _transport.Input.ReadAsync()).Buffer;
78var readableBuffer = (await _transport.Input.ReadAsync()).Buffer;
95var readableBuffer = (await _transport.Input.ReadAsync()).Buffer;
121var readableBuffer = (await _transport.Input.ReadAsync()).Buffer;
224if (reader.TryReadTo(out ReadOnlySequence<byte> _, new byte[] { (byte)'\r', (byte)'\n', (byte)'\r', (byte)'\n' }, advancePastDelimiter: true))
274var readableBuffer = (await _transport.Input.ReadAsync()).Buffer;
411var readableBuffer = (await _transport.Input.ReadAsync()).Buffer;
434var readableBuffer = (await _transport.Input.ReadAsync()).Buffer;
464var readableBuffer = (await _transport.Input.ReadAsync()).Buffer;
477var readableBuffer = (await _transport.Input.ReadAsync()).Buffer;
491var readableBuffer = (await _transport.Input.ReadAsync()).Buffer;
508var readableBuffer = (await _transport.Input.ReadAsync()).Buffer;
525var readableBuffer = (await _transport.Input.ReadAsync()).Buffer;
542var readableBuffer = (await _transport.Input.ReadAsync()).Buffer;
557var readableBuffer = (await _transport.Input.ReadAsync()).Buffer;
846var readableBuffer = (await _transport.Input.ReadAsync()).Buffer;
1040private bool TakeMessageHeaders(ReadOnlySequence<byte> readableBuffer, bool trailers, out SequencePosition consumed, out SequencePosition examined)
1057private bool TakeStartLine(ReadOnlySequence<byte> readableBuffer, out SequencePosition consumed, out SequencePosition examined)
1074private bool ParseRequest(ReadOnlySequence<byte> readableBuffer, out SequencePosition consumed, out SequencePosition examined)
HttpParserTests.cs (34)
38var buffer = new ReadOnlySequence<byte>(Encoding.ASCII.GetBytes(requestLine));
57var buffer = new ReadOnlySequence<byte>(Encoding.ASCII.GetBytes(requestLine));
68var buffer = new ReadOnlySequence<byte>(Encoding.ASCII.GetBytes(requestLine));
82var buffer = new ReadOnlySequence<byte>(Encoding.ASCII.GetBytes(requestLine));
105var buffer = new ReadOnlySequence<byte>(Encoding.ASCII.GetBytes(requestLine));
116var buffer = new ReadOnlySequence<byte>(Encoding.ASCII.GetBytes(requestLine));
135var buffer = new ReadOnlySequence<byte>(Encoding.ASCII.GetBytes(requestLine));
163var buffer = new ReadOnlySequence<byte>(Encoding.ASCII.GetBytes(requestLine));
181var buffer = new ReadOnlySequence<byte>(Encoding.ASCII.GetBytes(requestLine));
234var buffer = new ReadOnlySequence<byte>(Encoding.ASCII.GetBytes(rawHeaders));
260var buffer = new ReadOnlySequence<byte>(Encoding.ASCII.GetBytes(rawHeaders));
462var buffer1 = new ReadOnlySequence<byte>(Encoding.ASCII.GetBytes(headerLine));
470var buffer2 = new ReadOnlySequence<byte>(Encoding.ASCII.GetBytes("\r\n"));
483var buffer = new ReadOnlySequence<byte>(Encoding.ASCII.GetBytes(rawHeaders));
503var buffer = new ReadOnlySequence<byte>(Encoding.ASCII.GetBytes(rawHeaders));
524var buffer = new ReadOnlySequence<byte>(Encoding.ASCII.GetBytes("GET % HTTP/1.1\r\n"));
565var buffer = ReadOnlySequenceFactory.CreateSegments(
581var buffer = ReadOnlySequenceFactory.CreateSegments(new byte[] { 0x16, 0x03, 0x01, 0x02, 0x00, 0x01, 0x00, 0xfc, 0x03, 0x03, 0x03, 0xca, 0xe0, 0xfd, 0x0a });
601var buffer = BytePerSegmentTestSequenceFactory.Instance.CreateWithContent(rawHeaders);
621var buffer = BytePerSegmentTestSequenceFactory.Instance.CreateWithContent(rawHeaders);
642var buffer = BytePerSegmentTestSequenceFactory.Instance.CreateWithContent(headers);
656var buffer = BytePerSegmentTestSequenceFactory.Instance.CreateWithContent(headers);
670var buffer = new ReadOnlySequence<byte>(Encoding.ASCII.GetBytes(headers));
688var buffer = BytePerSegmentTestSequenceFactory.Instance.CreateWithContent(headers);
704var buffer = BytePerSegmentTestSequenceFactory.Instance.CreateWithContent(headers);
725var buffer = ReadOnlySequenceFactory.CreateSegments(
740var buffer = ReadOnlySequenceFactory.CreateSegments(
768var buffer = ReadOnlySequenceFactory.CreateSegments(
781var buffer = ReadOnlySequenceFactory.CreateSegments(
798private bool ParseRequestLine(IHttpParser<RequestHandler> parser, RequestHandler requestHandler, ReadOnlySequence<byte> readableBuffer, out SequencePosition consumed, out SequencePosition examined)
821var buffer = new ReadOnlySequence<byte>(Encoding.ASCII.GetBytes($"{headerName}:{rawHeaderValue}\r\n"));
839var buffer = new ReadOnlySequence<byte>(Encoding.ASCII.GetBytes(rawHeaders));
938public override ReadOnlySequence<byte> CreateOfSize(int size)
943public override ReadOnlySequence<byte> CreateWithContent(byte[] data)
Microsoft.AspNetCore.Server.Kestrel.Microbenchmarks (17)
Microsoft.AspNetCore.Server.Kestrel.Transport.NamedPipes (1)
Microsoft.AspNetCore.Server.Kestrel.Transport.Quic (1)
Microsoft.AspNetCore.Server.Kestrel.Transport.Sockets (3)
Microsoft.AspNetCore.Shared.Tests (22)
Microsoft.AspNetCore.SignalR.Client.Core (2)
Microsoft.AspNetCore.SignalR.Client.FunctionalTests (6)
Microsoft.AspNetCore.SignalR.Client.Tests (7)
Microsoft.AspNetCore.SignalR.Common (14)
Microsoft.AspNetCore.SignalR.Common.Tests (84)
Microsoft.AspNetCore.SignalR.Core (4)
Microsoft.AspNetCore.SignalR.Microbenchmarks (57)
Microsoft.AspNetCore.SignalR.Protocols.Json (12)
Microsoft.AspNetCore.SignalR.Protocols.MessagePack (7)
Microsoft.AspNetCore.SignalR.Protocols.NewtonsoftJson (9)
Microsoft.AspNetCore.SignalR.Specification.Tests (2)
Microsoft.AspNetCore.SignalR.StackExchangeRedis (3)
Microsoft.AspNetCore.SignalR.StackExchangeRedis.Tests (1)
Microsoft.AspNetCore.SignalR.Tests (17)
Microsoft.AspNetCore.SignalR.Tests.Utils (4)
Microsoft.AspNetCore.TestHost (1)
Microsoft.AspNetCore.WebUtilities (7)
Microsoft.AspNetCore.WebUtilities.Microbenchmarks (16)
Microsoft.AspNetCore.WebUtilities.Tests (37)
Microsoft.Extensions.Caching.Abstractions (3)
Microsoft.Extensions.Caching.Hybrid (4)
Microsoft.Extensions.Caching.Hybrid.Tests (9)
Microsoft.Extensions.Caching.SqlServer (3)
Microsoft.Extensions.Caching.StackExchangeRedis (5)
RedisCache.cs (5)
131private static ReadOnlyMemory<byte> Linearize(in ReadOnlySequence<byte> value, out byte[]? lease)
158void IBufferDistributedCache.Set(string key, ReadOnlySequence<byte> value, DistributedCacheEntryOptions options)
161private void SetImpl(string key, ReadOnlySequence<byte> value, DistributedCacheEntryOptions options)
205ValueTask IBufferDistributedCache.SetAsync(string key, ReadOnlySequence<byte> value, DistributedCacheEntryOptions options, CancellationToken token)
208private async Task SetImplAsync(string key, ReadOnlySequence<byte> value, DistributedCacheEntryOptions options, CancellationToken token = default)
mscorlib (1)
netstandard (1)
SignalR.Client.FunctionalTestApp (1)
SignalRSamples (1)
SocialWeather (1)
System.IO.Pipelines (19)
System.Memory (112)
System\Buffers\ReadOnlySequence.cs (43)
24/// Returns empty <see cref="ReadOnlySequence{T}"/>
26public static readonly ReadOnlySequence<T> Empty = new ReadOnlySequence<T>(Array.Empty<T>());
29/// Length of the <see cref="ReadOnlySequence{T}"/>.
34/// Determines if the <see cref="ReadOnlySequence{T}"/> is empty.
39/// Determines if the <see cref="ReadOnlySequence{T}"/> contains a single <see cref="ReadOnlyMemory{T}"/> segment.
58/// A position to the start of the <see cref="ReadOnlySequence{T}"/>.
67/// A position to the end of the <see cref="ReadOnlySequence{T}"/>
91/// Creates an instance of <see cref="ReadOnlySequence{T}"/> from linked memory list represented by start and end segments
111/// Creates an instance of <see cref="ReadOnlySequence{T}"/> from the array.
125/// Creates an instance of <see cref="ReadOnlySequence{T}"/> from the array, start, and index.
141/// Creates an instance of <see cref="ReadOnlySequence{T}"/> from the <see cref="ReadOnlyMemory{T}"/>.
142/// Consumer is expected to manage lifetime of memory until <see cref="ReadOnlySequence{T}"/> is not used anymore.
184/// Forms a slice out of the current <see cref="ReadOnlySequence{T}"/>, beginning at <paramref name="start"/>, with <paramref name="length"/> items.
189public ReadOnlySequence<T> Slice(long start, long length)
260/// Forms a slice out of the current <see cref="ReadOnlySequence{T}"/>, beginning at <paramref name="start"/> and ending at <paramref name="end"/> (exclusive).
265public ReadOnlySequence<T> Slice(long start, SequencePosition end)
339/// Forms a slice out of the current <see cref="ReadOnlySequence{T}"/>, beginning at <paramref name="start"/>, with <paramref name="length"/> items.
344public ReadOnlySequence<T> Slice(SequencePosition start, long length)
422/// Forms a slice out of the current <see cref="ReadOnlySequence{T}"/>, beginning at <paramref name="start"/>, with <paramref name="length"/> items.
427public ReadOnlySequence<T> Slice(int start, int length) => Slice((long)start, length);
430/// Forms a slice out of the current <see cref="ReadOnlySequence{T}"/>, beginning at <paramref name="start"/> and ending at <paramref name="end"/> (exclusive).
435public ReadOnlySequence<T> Slice(int start, SequencePosition end) => Slice((long)start, end);
438/// Forms a slice out of the current <see cref="ReadOnlySequence{T}"/>, beginning at <paramref name="start"/>, with <paramref name="length"/> items.
443public ReadOnlySequence<T> Slice(SequencePosition start, int length) => Slice(start, (long)length);
446/// Forms a slice out of the given <see cref="ReadOnlySequence{T}"/>, beginning at <paramref name="start"/>, ending at <paramref name="end"/> (exclusive).
452public ReadOnlySequence<T> Slice(SequencePosition start, SequencePosition end)
459/// Forms a slice out of the current <see cref="ReadOnlySequence{T}" />, beginning at a specified sequence position and continuing to the end of the read-only sequence.
464public ReadOnlySequence<T> Slice(SequencePosition start)
472/// Forms a slice out of the current <see cref="ReadOnlySequence{T}" /> , beginning at a specified index and continuing to the end of the read-only sequence.
476public ReadOnlySequence<T> Slice(long start)
493ReadOnlySequence<T> localThis = this;
494ReadOnlySequence<char> charSequence = Unsafe.As<ReadOnlySequence<T>, ReadOnlySequence<char>>(ref localThis);
511/// Returns an enumerator over the <see cref="ReadOnlySequence{T}"/>
597/// Returns <code>false</code> if end of <see cref="ReadOnlySequence{T}"/> was reached otherwise <code>true</code>.
612/// An enumerator over the <see cref="ReadOnlySequence{T}"/>
616private readonly ReadOnlySequence<T> _sequence;
621/// <param name="sequence">The <see cref="ReadOnlySequence{T}"/> to enumerate.</param>
622public Enumerator(in ReadOnlySequence<T> sequence)
635/// Moves to the next <see cref="ReadOnlyMemory{T}"/> in the <see cref="ReadOnlySequence{T}"/>
661/// Flag that allows encoding the <see cref="ReadOnlySequence{T}.SequenceType"/>.
663/// <seealso cref="ReadOnlySequence{T}.GetSequenceType"/>
System\Buffers\SequenceReader.Search.cs (12)
35if (!TryReadToInternal(out ReadOnlySequence<T> sequence, delimiter, advancePastDelimiter, CurrentSpan.Length - CurrentSpanIndex))
72if (!TryReadToSlow(out ReadOnlySequence<T> sequence, delimiter, delimiterEscape, index, advancePastDelimiter))
83private bool TryReadToSlow(out ReadOnlySequence<T> sequence, T delimiter, T delimiterEscape, int index, bool advancePastDelimiter)
188public bool TryReadTo(out ReadOnlySequence<T> sequence, T delimiter, bool advancePastDelimiter = true)
193private bool TryReadToInternal(out ReadOnlySequence<T> sequence, T delimiter, bool advancePastDelimiter, int skip = 0)
239public bool TryReadTo(out ReadOnlySequence<T> sequence, T delimiter, T delimiterEscape, bool advancePastDelimiter = true)
347if (!TryReadToAnyInternal(out ReadOnlySequence<T> sequence, delimiters, advancePastDelimiter, CurrentSpan.Length - CurrentSpanIndex))
364public bool TryReadToAny(out ReadOnlySequence<T> sequence, scoped ReadOnlySpan<T> delimiters, bool advancePastDelimiter = true)
369private bool TryReadToAnyInternal(out ReadOnlySequence<T> sequence, scoped ReadOnlySpan<T> delimiters, bool advancePastDelimiter, int skip = 0)
433if (!TryReadTo(out ReadOnlySequence<T> sequence, delimiter, advancePastDelimiter))
451public bool TryReadTo(out ReadOnlySequence<T> sequence, scoped ReadOnlySpan<T> delimiter, bool advancePastDelimiter = true)
511public bool TryReadExact(int count, out ReadOnlySequence<T> sequence)
System\Text\EncodingExtensions.cs (28)
61/// Decodes the specified <see cref="ReadOnlySequence{Char}"/> to <see langword="byte"/>s using the specified <see cref="Encoding"/>
65/// <param name="chars">The <see cref="ReadOnlySequence{Char}"/> whose contents should be encoded.</param>
70public static long GetBytes(this Encoding encoding, in ReadOnlySequence<char> chars, IBufferWriter<byte> writer)
90/// Encodes the specified <see cref="ReadOnlySequence{Char}"/> to <see langword="byte"/>s using the specified <see cref="Encoding"/>
94/// <param name="chars">The <see cref="ReadOnlySequence{Char}"/> to encode to <see langword="byte"/>s.</param>
100public static int GetBytes(this Encoding encoding, in ReadOnlySequence<char> chars, Span<byte> bytes)
115ReadOnlySequence<char> remainingChars = chars;
135/// Encodes the specified <see cref="ReadOnlySequence{Char}"/> into a <see cref="byte"/> array using the specified <see cref="Encoding"/>.
138/// <param name="chars">The <see cref="ReadOnlySequence{Char}"/> to encode to <see langword="byte"/>s.</param>
142public static byte[] GetBytes(this Encoding encoding, in ReadOnlySequence<char> chars)
169ReadOnlySequence<char> remainingChars = chars;
252/// Decodes the specified <see cref="ReadOnlySequence{Byte}"/> to <see langword="char"/>s using the specified <see cref="Encoding"/>
256/// <param name="bytes">The <see cref="ReadOnlySequence{Byte}"/> whose bytes should be decoded.</param>
261public static long GetChars(this Encoding encoding, in ReadOnlySequence<byte> bytes, IBufferWriter<char> writer)
281/// Decodes the specified <see cref="ReadOnlySequence{Byte}"/> to <see langword="char"/>s using the specified <see cref="Encoding"/>
285/// <param name="bytes">The <see cref="ReadOnlySequence{Byte}"/> to decode to characters.</param>
291public static int GetChars(this Encoding encoding, in ReadOnlySequence<byte> bytes, Span<char> chars)
306ReadOnlySequence<byte> remainingBytes = bytes;
326/// Decodes the specified <see cref="ReadOnlySequence{Byte}"/> into a <see cref="string"/> using the specified <see cref="Encoding"/>.
329/// <param name="bytes">The <see cref="ReadOnlySequence{Byte}"/> to decode into characters.</param>
333public static string GetString(this Encoding encoding, in ReadOnlySequence<byte> bytes)
356ReadOnlySequence<byte> remainingBytes = bytes;
449/// Converts a <see cref="ReadOnlySequence{Char}"/> to encoded bytes and writes the result to <paramref name="writer"/>.
461public static void Convert(this Encoder encoder, in ReadOnlySequence<char> chars, IBufferWriter<byte> writer, bool flush, out long bytesUsed, out bool completed)
471ReadOnlySequence<char> remainingChars = chars;
542/// Converts a <see cref="ReadOnlySequence{Byte}"/> to UTF-16 encoded characters and writes the result to <paramref name="writer"/>.
555public static void Convert(this Decoder decoder, in ReadOnlySequence<byte> bytes, IBufferWriter<char> writer, bool flush, out long charsUsed, out bool completed)
565ReadOnlySequence<byte> remainingBytes = bytes;
System.Net.Http (3)
System.Text.Json (24)