aboutsummaryrefslogtreecommitdiff
path: root/MediaBrowser.Model/Net
diff options
context:
space:
mode:
Diffstat (limited to 'MediaBrowser.Model/Net')
-rw-r--r--MediaBrowser.Model/Net/EndPointInfo.cs2
-rw-r--r--MediaBrowser.Model/Net/HttpException.cs2
-rw-r--r--MediaBrowser.Model/Net/ISocket.cs4
-rw-r--r--MediaBrowser.Model/Net/ISocketFactory.cs12
-rw-r--r--MediaBrowser.Model/Net/MimeTypes.cs14
-rw-r--r--MediaBrowser.Model/Net/NetworkShare.cs2
-rw-r--r--MediaBrowser.Model/Net/NetworkShareType.cs16
-rw-r--r--MediaBrowser.Model/Net/SocketReceiveResult.cs2
-rw-r--r--MediaBrowser.Model/Net/WebSocketMessage.cs5
9 files changed, 33 insertions, 26 deletions
diff --git a/MediaBrowser.Model/Net/EndPointInfo.cs b/MediaBrowser.Model/Net/EndPointInfo.cs
index b73799ea8..f5ac3d169 100644
--- a/MediaBrowser.Model/Net/EndPointInfo.cs
+++ b/MediaBrowser.Model/Net/EndPointInfo.cs
@@ -1,3 +1,5 @@
+#pragma warning disable CS1591
+
namespace MediaBrowser.Model.Net
{
public class EndPointInfo
diff --git a/MediaBrowser.Model/Net/HttpException.cs b/MediaBrowser.Model/Net/HttpException.cs
index 16253ed6c..4b15e30f0 100644
--- a/MediaBrowser.Model/Net/HttpException.cs
+++ b/MediaBrowser.Model/Net/HttpException.cs
@@ -4,7 +4,7 @@ using System.Net;
namespace MediaBrowser.Model.Net
{
/// <summary>
- /// Class HttpException
+ /// Class HttpException.
/// </summary>
public class HttpException : Exception
{
diff --git a/MediaBrowser.Model/Net/ISocket.cs b/MediaBrowser.Model/Net/ISocket.cs
index f80de5524..2bfbfcb20 100644
--- a/MediaBrowser.Model/Net/ISocket.cs
+++ b/MediaBrowser.Model/Net/ISocket.cs
@@ -1,3 +1,5 @@
+#pragma warning disable CS1591
+
using System;
using System.Net;
using System.Threading;
@@ -14,8 +16,6 @@ namespace MediaBrowser.Model.Net
Task<SocketReceiveResult> ReceiveAsync(byte[] buffer, int offset, int count, CancellationToken cancellationToken);
- int Receive(byte[] buffer, int offset, int count);
-
IAsyncResult BeginReceive(byte[] buffer, int offset, int count, AsyncCallback callback);
SocketReceiveResult EndReceive(IAsyncResult result);
diff --git a/MediaBrowser.Model/Net/ISocketFactory.cs b/MediaBrowser.Model/Net/ISocketFactory.cs
index 2f857f1af..363abefc1 100644
--- a/MediaBrowser.Model/Net/ISocketFactory.cs
+++ b/MediaBrowser.Model/Net/ISocketFactory.cs
@@ -1,4 +1,5 @@
-using System.IO;
+#pragma warning disable CS1591
+
using System.Net;
namespace MediaBrowser.Model.Net
@@ -8,13 +9,6 @@ namespace MediaBrowser.Model.Net
/// </summary>
public interface ISocketFactory
{
- /// <summary>
- /// Creates a new unicast socket using the specified local port number.
- /// </summary>
- /// <param name="localPort">The local port to bind to.</param>
- /// <returns>A <see cref="ISocket"/> implementation.</returns>
- ISocket CreateUdpSocket(int localPort);
-
ISocket CreateUdpBroadcastSocket(int localPort);
/// <summary>
@@ -30,7 +24,5 @@ namespace MediaBrowser.Model.Net
/// <param name="localPort">The local port to bind to.</param>
/// <returns>A <see cref="ISocket"/> implementation.</returns>
ISocket CreateUdpMulticastSocket(string ipAddress, int multicastTimeToLive, int localPort);
-
- Stream CreateNetworkStream(ISocket socket, bool ownsSocket);
}
}
diff --git a/MediaBrowser.Model/Net/MimeTypes.cs b/MediaBrowser.Model/Net/MimeTypes.cs
index de5e58d22..68bcc590c 100644
--- a/MediaBrowser.Model/Net/MimeTypes.cs
+++ b/MediaBrowser.Model/Net/MimeTypes.cs
@@ -1,8 +1,9 @@
+#pragma warning disable CS1591
+
using System;
using System.Collections.Generic;
using System.IO;
using System.Linq;
-using MediaBrowser.Model.Extensions;
namespace MediaBrowser.Model.Net
{
@@ -63,6 +64,7 @@ namespace MediaBrowser.Model.Net
{ ".m3u8", "application/x-mpegURL" },
{ ".mobi", "application/x-mobipocket-ebook" },
{ ".xml", "application/xml" },
+ { ".wasm", "application/wasm" },
// Type image
{ ".jpg", "image/jpeg" },
@@ -165,20 +167,20 @@ namespace MediaBrowser.Model.Net
}
// Type text
- if (StringHelper.EqualsIgnoreCase(ext, ".html")
- || StringHelper.EqualsIgnoreCase(ext, ".htm"))
+ if (string.Equals(ext, ".html", StringComparison.OrdinalIgnoreCase)
+ || string.Equals(ext, ".htm", StringComparison.OrdinalIgnoreCase))
{
return "text/html; charset=UTF-8";
}
- if (StringHelper.EqualsIgnoreCase(ext, ".log")
- || StringHelper.EqualsIgnoreCase(ext, ".srt"))
+ if (string.Equals(ext, ".log", StringComparison.OrdinalIgnoreCase)
+ || string.Equals(ext, ".srt", StringComparison.OrdinalIgnoreCase))
{
return "text/plain";
}
// Misc
- if (StringHelper.EqualsIgnoreCase(ext, ".dll"))
+ if (string.Equals(ext, ".dll", StringComparison.OrdinalIgnoreCase))
{
return "application/octet-stream";
}
diff --git a/MediaBrowser.Model/Net/NetworkShare.cs b/MediaBrowser.Model/Net/NetworkShare.cs
index 1f61414fc..744c6ec14 100644
--- a/MediaBrowser.Model/Net/NetworkShare.cs
+++ b/MediaBrowser.Model/Net/NetworkShare.cs
@@ -1,3 +1,5 @@
+#pragma warning disable CS1591
+
namespace MediaBrowser.Model.Net
{
public class NetworkShare
diff --git a/MediaBrowser.Model/Net/NetworkShareType.cs b/MediaBrowser.Model/Net/NetworkShareType.cs
index bf2d092a6..5d985f85d 100644
--- a/MediaBrowser.Model/Net/NetworkShareType.cs
+++ b/MediaBrowser.Model/Net/NetworkShareType.cs
@@ -1,28 +1,32 @@
namespace MediaBrowser.Model.Net
{
/// <summary>
- /// Enum NetworkShareType
+ /// Enum NetworkShareType.
/// </summary>
public enum NetworkShareType
{
/// <summary>
- /// Disk share
+ /// Disk share.
/// </summary>
Disk,
+
/// <summary>
- /// Printer share
+ /// Printer share.
/// </summary>
Printer,
+
/// <summary>
- /// Device share
+ /// Device share.
/// </summary>
Device,
+
/// <summary>
- /// IPC share
+ /// IPC share.
/// </summary>
Ipc,
+
/// <summary>
- /// Special share
+ /// Special share.
/// </summary>
Special
}
diff --git a/MediaBrowser.Model/Net/SocketReceiveResult.cs b/MediaBrowser.Model/Net/SocketReceiveResult.cs
index 3a4ad3738..141ae1608 100644
--- a/MediaBrowser.Model/Net/SocketReceiveResult.cs
+++ b/MediaBrowser.Model/Net/SocketReceiveResult.cs
@@ -1,3 +1,5 @@
+#pragma warning disable CS1591
+
using System.Net;
namespace MediaBrowser.Model.Net
diff --git a/MediaBrowser.Model/Net/WebSocketMessage.cs b/MediaBrowser.Model/Net/WebSocketMessage.cs
index c763216f1..7575224d4 100644
--- a/MediaBrowser.Model/Net/WebSocketMessage.cs
+++ b/MediaBrowser.Model/Net/WebSocketMessage.cs
@@ -1,7 +1,9 @@
+#pragma warning disable CS1591
+
namespace MediaBrowser.Model.Net
{
/// <summary>
- /// Class WebSocketMessage
+ /// Class WebSocketMessage.
/// </summary>
/// <typeparam name="T"></typeparam>
public class WebSocketMessage<T>
@@ -13,6 +15,7 @@ namespace MediaBrowser.Model.Net
public string MessageType { get; set; }
public string MessageId { get; set; }
public string ServerId { get; set; }
+
/// <summary>
/// Gets or sets the data.
/// </summary>