C# Class Helios.Net.Connections.TcpConnection

Inheritance: UnstreamedConnectionBase
Afficher le fichier Open project: helios-io/helios

Protected Properties

Свойство Type Description
_client Socket

Méthodes publiques

Méthode Description
Close ( ) : void
Close ( Exception reason ) : void
Configure ( IConnectionConfig config ) : void
IsOpen ( ) : bool
Open ( ) : void
OpenAsync ( ) : Task
TcpConnection ( NetworkEventLoop eventLoop, INode node, IMessageEncoder encoder, IMessageDecoder decoder, IByteBufAllocator allocator, int bufferSize = NetworkConstants.DEFAULT_BUFFER_SIZE ) : System
TcpConnection ( NetworkEventLoop eventLoop, INode node, System.TimeSpan timeout, IMessageEncoder encoder, IMessageDecoder decoder, IByteBufAllocator allocator, int bufferSize = NetworkConstants.DEFAULT_BUFFER_SIZE ) : System
TcpConnection ( Socket client, IMessageEncoder encoder, IMessageDecoder decoder, IByteBufAllocator allocator, int bufferSize = NetworkConstants.DEFAULT_BUFFER_SIZE ) : System
TcpConnection ( Socket client, int bufferSize = NetworkConstants.DEFAULT_BUFFER_SIZE ) : System

Méthodes protégées

Méthode Description
BeginReceiveInternal ( ) : void
Dispose ( bool disposing ) : void
SendInternal ( byte buffer, int index, int length, INode destination ) : void
SetLocal ( Socket client ) : void

After a TCP connection is successfully established, set the value of the local node to whatever port / IP was assigned.

Private Methods

Méthode Description
InitClient ( ) : void
InitClient ( Socket client ) : void

Method Details

BeginReceiveInternal() protected méthode

protected BeginReceiveInternal ( ) : void
Résultat void

Close() public méthode

public Close ( ) : void
Résultat void

Close() public méthode

public Close ( Exception reason ) : void
reason System.Exception
Résultat void

Configure() public méthode

public Configure ( IConnectionConfig config ) : void
config IConnectionConfig
Résultat void

Dispose() protected méthode

protected Dispose ( bool disposing ) : void
disposing bool
Résultat void

IsOpen() public méthode

public IsOpen ( ) : bool
Résultat bool

Open() public méthode

public Open ( ) : void
Résultat void

OpenAsync() public méthode

public OpenAsync ( ) : Task
Résultat Task

SendInternal() protected méthode

protected SendInternal ( byte buffer, int index, int length, INode destination ) : void
buffer byte
index int
length int
destination INode
Résultat void

SetLocal() protected méthode

After a TCP connection is successfully established, set the value of the local node to whatever port / IP was assigned.
protected SetLocal ( Socket client ) : void
client Socket
Résultat void

TcpConnection() public méthode

public TcpConnection ( NetworkEventLoop eventLoop, INode node, IMessageEncoder encoder, IMessageDecoder decoder, IByteBufAllocator allocator, int bufferSize = NetworkConstants.DEFAULT_BUFFER_SIZE ) : System
eventLoop NetworkEventLoop
node INode
encoder IMessageEncoder
decoder IMessageDecoder
allocator IByteBufAllocator
bufferSize int
Résultat System

TcpConnection() public méthode

public TcpConnection ( NetworkEventLoop eventLoop, INode node, System.TimeSpan timeout, IMessageEncoder encoder, IMessageDecoder decoder, IByteBufAllocator allocator, int bufferSize = NetworkConstants.DEFAULT_BUFFER_SIZE ) : System
eventLoop NetworkEventLoop
node INode
timeout System.TimeSpan
encoder IMessageEncoder
decoder IMessageDecoder
allocator IByteBufAllocator
bufferSize int
Résultat System

TcpConnection() public méthode

public TcpConnection ( Socket client, IMessageEncoder encoder, IMessageDecoder decoder, IByteBufAllocator allocator, int bufferSize = NetworkConstants.DEFAULT_BUFFER_SIZE ) : System
client Socket
encoder IMessageEncoder
decoder IMessageDecoder
allocator IByteBufAllocator
bufferSize int
Résultat System

TcpConnection() public méthode

public TcpConnection ( Socket client, int bufferSize = NetworkConstants.DEFAULT_BUFFER_SIZE ) : System
client Socket
bufferSize int
Résultat System

Property Details

_client protected_oe property

protected Socket _client
Résultat Socket