diff options
| author | Bond-009 <bond.009@outlook.com> | 2020-02-04 12:21:42 +0100 |
|---|---|---|
| committer | Bond-009 <bond.009@outlook.com> | 2020-02-04 12:21:42 +0100 |
| commit | ba1ffbabd3c1fc610b3f0a3de47dbc670920f915 (patch) | |
| tree | 069c76ee43d1bb5ca4ee1f72f0c95edfe484ed7e /MediaBrowser.Common/Net/HttpRequestOptions.cs | |
| parent | 5dc3874ebdeac26d7be885b9a44ca1321b4b25cf (diff) | |
| parent | 176e8509739ffd3d7002c94adbd814c33b5172e2 (diff) | |
Merge branch 'master' into nullable2
Diffstat (limited to 'MediaBrowser.Common/Net/HttpRequestOptions.cs')
| -rw-r--r-- | MediaBrowser.Common/Net/HttpRequestOptions.cs | 28 |
1 files changed, 16 insertions, 12 deletions
diff --git a/MediaBrowser.Common/Net/HttpRequestOptions.cs b/MediaBrowser.Common/Net/HttpRequestOptions.cs index 18c4b181f..8207a45f3 100644 --- a/MediaBrowser.Common/Net/HttpRequestOptions.cs +++ b/MediaBrowser.Common/Net/HttpRequestOptions.cs @@ -1,4 +1,5 @@ #pragma warning disable CS1591 +#pragma warning disable SA1600 using System; using System.Collections.Generic; @@ -8,11 +9,22 @@ using Microsoft.Net.Http.Headers; namespace MediaBrowser.Common.Net { /// <summary> - /// Class HttpRequestOptions + /// Class HttpRequestOptions. /// </summary> public class HttpRequestOptions { /// <summary> + /// Initializes a new instance of the <see cref="HttpRequestOptions"/> class. + /// </summary> + public HttpRequestOptions() + { + RequestHeaders = new Dictionary<string, string>(StringComparer.OrdinalIgnoreCase); + + CacheMode = CacheMode.None; + DecompressionMethod = CompressionMethod.Deflate; + } + + /// <summary> /// Gets or sets the URL. /// </summary> /// <value>The URL.</value> @@ -71,14 +83,17 @@ namespace MediaBrowser.Common.Net public string RequestContentType { get; set; } public string RequestContent { get; set; } + public byte[] RequestContentBytes { get; set; } public bool BufferContent { get; set; } public bool LogErrorResponseBody { get; set; } + public bool EnableKeepAlive { get; set; } public CacheMode CacheMode { get; set; } + public TimeSpan CacheLength { get; set; } public bool EnableDefaultUserAgent { get; set; } @@ -89,17 +104,6 @@ namespace MediaBrowser.Common.Net return value; } - - /// <summary> - /// Initializes a new instance of the <see cref="HttpRequestOptions"/> class. - /// </summary> - public HttpRequestOptions() - { - RequestHeaders = new Dictionary<string, string>(StringComparer.OrdinalIgnoreCase); - - CacheMode = CacheMode.None; - DecompressionMethod = CompressionMethod.Deflate; - } } public enum CacheMode |
