Class Tcp.Connect
The Connect message is sent to the TCP manager actor, which is obtained via Manager. Either the manager replies with a Tcp.CommandFailed or the actor handling the new connection replies with a Tcp.Connected message.
Implements
Inherited Members
Namespace: Akka.IO
Assembly: Akka.dll
Syntax
public sealed class Tcp.Connect : Tcp.Command, INoSerializationVerificationNeeded
Constructors
| Edit this page View SourceConnect(EndPoint, EndPoint, IEnumerable<SocketOption>, TimeSpan?, bool)
Connect to a remote TCP endpoint.
Declaration
public Connect(EndPoint remoteAddress, EndPoint localAddress = null, IEnumerable<Inet.SocketOption> options = null, TimeSpan? timeout = null, bool pullMode = false)
Parameters
Type | Name | Description |
---|---|---|
EndPoint | remoteAddress | The remote endpoint |
EndPoint | localAddress | An optional local endpoint address to bind to. Most users don't specify this. |
IEnumerable<Inet.SocketOption> | options | A set of socket options. |
TimeSpan? | timeout | An optional connect timeout. Will result in a Tcp.CommandFailed message being returned if we exceed this value. |
bool | pullMode | Specifies whether we're running in "pull mode" or not. |
Properties
| Edit this page View SourceLocalAddress
Declaration
public EndPoint LocalAddress { get; }
Property Value
Type | Description |
---|---|
EndPoint |
Options
Declaration
public IEnumerable<Inet.SocketOption> Options { get; }
Property Value
Type | Description |
---|---|
IEnumerable<Inet.SocketOption> |
PullMode
Declaration
public bool PullMode { get; }
Property Value
Type | Description |
---|---|
bool |
RemoteAddress
Declaration
public EndPoint RemoteAddress { get; }
Property Value
Type | Description |
---|---|
EndPoint |
Timeout
Declaration
public TimeSpan? Timeout { get; }
Property Value
Type | Description |
---|---|
TimeSpan? |
Methods
| Edit this page View SourceToString()
Declaration
public override string ToString()
Returns
Type | Description |
---|---|
string |