2020-04-05 09:10:56 -07:00
|
|
|
#nullable disable
|
2020-02-03 17:49:27 -07:00
|
|
|
|
2019-07-07 12:03:26 -07:00
|
|
|
using System.Net;
|
|
|
|
|
2018-12-27 16:27:57 -07:00
|
|
|
namespace MediaBrowser.Model.Net
|
|
|
|
{
|
|
|
|
/// <summary>
|
|
|
|
/// Used by the sockets wrapper to hold raw data received from a UDP socket.
|
|
|
|
/// </summary>
|
|
|
|
public sealed class SocketReceiveResult
|
2019-01-07 16:24:34 -07:00
|
|
|
{
|
|
|
|
/// <summary>
|
2020-04-05 09:10:56 -07:00
|
|
|
/// Gets or sets the buffer to place received data into.
|
2019-01-07 16:24:34 -07:00
|
|
|
/// </summary>
|
|
|
|
public byte[] Buffer { get; set; }
|
2018-12-27 16:27:57 -07:00
|
|
|
|
2019-01-07 16:24:34 -07:00
|
|
|
/// <summary>
|
2020-04-05 09:10:56 -07:00
|
|
|
/// Gets or sets the number of bytes received.
|
2019-01-07 16:24:34 -07:00
|
|
|
/// </summary>
|
|
|
|
public int ReceivedBytes { get; set; }
|
2018-12-27 16:27:57 -07:00
|
|
|
|
|
|
|
/// <summary>
|
2021-02-20 15:13:04 -07:00
|
|
|
/// Gets or sets the <see cref="IPEndPoint"/> the data was received from.
|
2018-12-27 16:27:57 -07:00
|
|
|
/// </summary>
|
2019-07-07 12:03:26 -07:00
|
|
|
public IPEndPoint RemoteEndPoint { get; set; }
|
2020-04-05 09:10:56 -07:00
|
|
|
|
|
|
|
/// <summary>
|
2021-02-20 15:13:04 -07:00
|
|
|
/// Gets or sets the local <see cref="IPAddress"/>.
|
2020-04-05 09:10:56 -07:00
|
|
|
/// </summary>
|
2019-07-07 12:03:26 -07:00
|
|
|
public IPAddress LocalIPAddress { get; set; }
|
2018-12-27 16:27:57 -07:00
|
|
|
}
|
|
|
|
}
|