Class EOSTransportManager.Connection
- Namespace
- PlayEveryWare.EpicOnlineServices.Samples.Network
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
socketNamestringThe 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
ConnectionOpenedHandled
Has the user been given the chance to handle the connection open event?
public bool ConnectionOpenedHandled
Field Value
IsValid
By design we don't re-use this Connection data structure after the connection lifecycle is complete.
public bool IsValid
Field Value
OpenedIncoming
If the incoming (remote) side of the connection has been opened.
public bool OpenedIncoming
Field Value
OpenedOutgoing
If the outgoing (local) side of the connection has been opened.
public bool OpenedOutgoing
Field Value
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
IsHalfOpened
If the connection has been opened on at least one end (local or remote).
public bool IsHalfOpened { get; }
Property Value
IsPendingIncoming
If the remote side of the connection is awaiting a connection accept response.
public bool IsPendingIncoming { get; }
Property Value
IsPendingOutgoing
If we are waiting on the remote side of the connection to confirm.
public bool IsPendingOutgoing { get; }
Property Value
SocketName
The name of the socket used by this Connection.
public string SocketName { get; set; }
Property Value
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
connectionEOSTransportManager.ConnectionThe Connection to compare to.
Returns
- bool
trueif the Connections match,falseif not.
Equals(object)
Checks if a given object is the same as this Connection.
public override bool Equals(object obj)
Parameters
objobjectThe object to compare to.
Returns
- bool
trueif the objects match,falseif not.
Equals(string)
Checks if the given socket name matches this Connection.
public bool Equals(string socketName)
Parameters
socketNamestringThe name of the socket to check.
Returns
- bool
trueif the socket name matches,falseif 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.