Table of Contents

Class EOSTransportManager.Connection

public class EOSTransportManager.Connection : IEquatable<EOSTransportManager.Connection>
Inheritance
EOSTransportManager.Connection
Implements
Inherited Members

Constructors

Connection()

Creates a Connection with no initial information.

public Connection()

Connection(string)

Creates a Connection with a given named socket.

public Connection(string socketName)

Parameters

socketName string

The name of the socket to use.

Fields

ConnectionClosedHandled

Has the user been given the chance to handle the connection closed event?

public bool ConnectionClosedHandled

Field Value

bool

ConnectionOpenedHandled

Has the user been given the chance to handle the connection open event?

public bool ConnectionOpenedHandled

Field Value

bool

IsValid

By design we don't re-use this Connection data structure after the connection lifecycle is complete.

public bool IsValid

Field Value

bool

OpenedIncoming

If the incoming (remote) side of the connection has been opened.

public bool OpenedIncoming

Field Value

bool

OpenedOutgoing

If the outgoing (local) side of the connection has been opened.

public bool OpenedOutgoing

Field Value

bool

SocketId

The ID of the socket for this Connection.

public SocketId SocketId

Field Value

SocketId

Properties

IsFullyOpened

If the connection has been opened on both the local and remote ends.

public bool IsFullyOpened { get; }

Property Value

bool

IsHalfOpened

If the connection has been opened on at least one end (local or remote).

public bool IsHalfOpened { get; }

Property Value

bool

IsPendingIncoming

If the remote side of the connection is awaiting a connection accept response.

public bool IsPendingIncoming { get; }

Property Value

bool

IsPendingOutgoing

If we are waiting on the remote side of the connection to confirm.

public bool IsPendingOutgoing { get; }

Property Value

bool

SocketName

The name of the socket used by this Connection.

public string SocketName { get; set; }

Property Value

string

Methods

DebugStringJSON()

Provides a JSON formatted debug string for this connection.

public string DebugStringJSON()

Returns

string

The JSON formatted debug string containing the socket ID and socket name.

Equals(Connection)

Checks if a given Connection object is the same as this Connection.

public bool Equals(EOSTransportManager.Connection connection)

Parameters

connection EOSTransportManager.Connection

The Connection to compare to.

Returns

bool

true if the Connections match, false if not.

Equals(object)

Checks if a given object is the same as this Connection.

public override bool Equals(object obj)

Parameters

obj object

The object to compare to.

Returns

bool

true if the objects match, false if not.

Equals(string)

Checks if the given socket name matches this Connection.

public bool Equals(string socketName)

Parameters

socketName string

The name of the socket to check.

Returns

bool

true if the socket name matches, false if not.

GetHashCode()

Gets the hash code for the socket.

public override int GetHashCode()

Returns

int

The hash code for this Connection's socket.

GetNextMessageIndex()

Gets the ID to use for the next outgoing message on this connection. Note: The index is updated after each call, and it is expected that the value given will be used.

public ushort GetNextMessageIndex()

Returns

ushort

The index to use for the next message.