< Summary

Information
Class: System.Net.Http.SocketsHttpPlaintextStreamFilterContext
Assembly: System.Net.Http
File(s): D:\runner\runtime\src\libraries\System.Net.Http\src\System\Net\Http\SocketsHttpHandler\SocketsHttpPlaintextStreamFilterContext.cs
Line coverage
0%
Covered lines: 0
Uncovered lines: 9
Coverable lines: 9
Total lines: 39
Line coverage: 0%
Branch coverage
N/A
Covered branches: 0
Total branches: 0
Branch coverage: N/A
Method coverage

Feature is only available for sponsors

Upgrade to PRO version

Metrics

MethodBranch coverage Cyclomatic complexity NPath complexity Sequence coverage
.ctor(...)100%110%

File(s)

D:\runner\runtime\src\libraries\System.Net.Http\src\System\Net\Http\SocketsHttpHandler\SocketsHttpPlaintextStreamFilterContext.cs

#LineLine coverage
 1// Licensed to the .NET Foundation under one or more agreements.
 2// The .NET Foundation licenses this file to you under the MIT license.
 3
 4using System.IO;
 5
 6namespace System.Net.Http
 7{
 8    /// <summary>
 9    /// Represents the context passed to the PlaintextStreamFilter for a SocketsHttpHandler instance.
 10    /// </summary>
 11    public sealed class SocketsHttpPlaintextStreamFilterContext
 12    {
 13        private readonly Stream _plaintextStream;
 14        private readonly Version _negotiatedHttpVersion;
 15        private readonly HttpRequestMessage _initialRequestMessage;
 16
 017        internal SocketsHttpPlaintextStreamFilterContext(Stream plaintextStream, Version negotiatedHttpVersion, HttpRequ
 018        {
 019            _plaintextStream = plaintextStream;
 020            _negotiatedHttpVersion = negotiatedHttpVersion;
 021            _initialRequestMessage = initialRequestMessage;
 022        }
 23
 24        /// <summary>
 25        /// The plaintext Stream that will be used for HTTP protocol requests and responses.
 26        /// </summary>
 027        public Stream PlaintextStream => _plaintextStream;
 28
 29        /// <summary>
 30        /// The version of HTTP in use for this stream.
 31        /// </summary>
 032        public Version NegotiatedHttpVersion => _negotiatedHttpVersion;
 33
 34        /// <summary>
 35        /// The initial HttpRequestMessage that is causing the stream to be used.
 36        /// </summary>
 037        public HttpRequestMessage InitialRequestMessage => _initialRequestMessage;
 38    }
 39}