Created
March 17, 2016 16:45
-
-
Save lukasz-pyrzyk/3f36d5e0f334f4ba8a9e to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
using System.Net; | |
using System.Net.Sockets; | |
namespace XGain.Sockets | |
{ | |
public interface ISocket : IDisposable | |
{ | |
int BufferSize { get; } | |
bool Connected { get; } | |
Socket InternalSocket { get; } | |
EndPoint LocalEndPoint { get; } | |
EndPoint RemoteEndPoint { get; } | |
ISocket Accept(); | |
void Bind(IPEndPoint localEndPoint); | |
void Connect(IPEndPoint remoteEndPoint); | |
void Listen(int backlog); | |
int Receive(byte[] buffer); | |
int Send(byte[] buffer); | |
void Shutdown(SocketShutdown how); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment