ModernUO/Projects/Server/Network/Sockets/ISocket.cs
2024-09-29 23:53:00 +02:00

18 lines
465 B
C#

using System;
using System.Net;
using System.Net.Sockets;
namespace Server.Network.Sockets
{
public interface ISocket
{
public Socket Socket { get; }
public bool Connected { get; }
public IPEndPoint? LocalEndPoint { get; }
public IPEndPoint? RemoteEndPoint { get; }
public int Send(ReadOnlySpan<byte> buffer);
public int Receive(Span<byte> buffer, out bool forceClose);
public void Close();
}
}