C# Class System.Net.Sockets.TcpClient

Afficher le fichier Open project: dotnet/corefx Class Usage Examples

Private Properties

Свойство Type Description
BeginConnectCore IAsyncResult
BeginConnectCore IAsyncResult
ConnectAsyncCore System.Threading.Tasks.Task
ConnectAsyncCore System.Threading.Tasks.Task
CreateSocket Socket
DisposeCore void
EndConnectCore void
InitializeClientSocket void
TcpClient System.Diagnostics

Méthodes publiques

Méthode Description
BeginConnect ( IPAddress address, int port, AsyncCallback requestCallback, object state ) : IAsyncResult
BeginConnect ( string host, int port, AsyncCallback requestCallback, object state ) : IAsyncResult
Close ( ) : void
Connect ( IPAddress address, int port ) : void
Connect ( IPEndPoint remoteEP ) : void
Connect ( string hostname, int port ) : void
ConnectAsync ( IPAddress address, int port ) : System.Threading.Tasks.Task
ConnectAsync ( string host, int port ) : System.Threading.Tasks.Task
Dispose ( ) : void
EndConnect ( IAsyncResult asyncResult ) : void
GetStream ( ) : NetworkStream
TcpClient ( IPEndPoint localEP )
TcpClient ( string hostname, int port )
TcpClient ( ) : System.Diagnostics
TcpClient ( AddressFamily family ) : System.Diagnostics

Méthodes protégées

Méthode Description
Dispose ( bool disposing ) : void

Private Methods

Méthode Description
BeginConnectCore ( IPAddress address, int port, AsyncCallback requestCallback, object state ) : IAsyncResult
BeginConnectCore ( string host, int port, AsyncCallback requestCallback, object state ) : IAsyncResult
ConnectAsyncCore ( IPAddress address, int port ) : System.Threading.Tasks.Task
ConnectAsyncCore ( string host, int port ) : System.Threading.Tasks.Task
CreateSocket ( ) : Socket
DisposeCore ( ) : void
EndConnectCore ( Socket socket, IAsyncResult asyncResult ) : void
InitializeClientSocket ( ) : void
TcpClient ( Socket acceptedSocket ) : System.Diagnostics

Method Details

BeginConnect() public méthode

public BeginConnect ( IPAddress address, int port, AsyncCallback requestCallback, object state ) : IAsyncResult
address IPAddress
port int
requestCallback AsyncCallback
state object
Résultat IAsyncResult

BeginConnect() public méthode

public BeginConnect ( string host, int port, AsyncCallback requestCallback, object state ) : IAsyncResult
host string
port int
requestCallback AsyncCallback
state object
Résultat IAsyncResult

Close() public méthode

public Close ( ) : void
Résultat void

Connect() public méthode

public Connect ( IPAddress address, int port ) : void
address IPAddress
port int
Résultat void

Connect() public méthode

public Connect ( IPEndPoint remoteEP ) : void
remoteEP IPEndPoint
Résultat void

Connect() public méthode

public Connect ( string hostname, int port ) : void
hostname string
port int
Résultat void

ConnectAsync() public méthode

public ConnectAsync ( IPAddress address, int port ) : System.Threading.Tasks.Task
address IPAddress
port int
Résultat System.Threading.Tasks.Task

ConnectAsync() public méthode

public ConnectAsync ( string host, int port ) : System.Threading.Tasks.Task
host string
port int
Résultat System.Threading.Tasks.Task

Dispose() public méthode

public Dispose ( ) : void
Résultat void

Dispose() protected méthode

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

EndConnect() public méthode

public EndConnect ( IAsyncResult asyncResult ) : void
asyncResult IAsyncResult
Résultat void

GetStream() public méthode

public GetStream ( ) : NetworkStream
Résultat NetworkStream

TcpClient() public méthode

public TcpClient ( IPEndPoint localEP )
localEP IPEndPoint

TcpClient() public méthode

public TcpClient ( string hostname, int port )
hostname string
port int

TcpClient() public méthode

public TcpClient ( ) : System.Diagnostics
Résultat System.Diagnostics

TcpClient() public méthode

public TcpClient ( AddressFamily family ) : System.Diagnostics
family AddressFamily
Résultat System.Diagnostics