Photon .NET Client API 4.1.4.8

Public Member Functions | Public Attributes | Protected Member Functions | Protected Attributes | Properties | List of all members
ExitGames.Client.Photon.IPhotonSocket Class Referenceabstract
Inheritance diagram for ExitGames.Client.Photon.IPhotonSocket:
ExitGames.Client.Photon.SocketNative ExitGames.Client.Photon.SocketTcp ExitGames.Client.Photon.SocketTcpAsync ExitGames.Client.Photon.SocketUdp ExitGames.Client.Photon.SocketUdpAsync

Public Member Functions

 IPhotonSocket (PeerBase peerBase)
 
virtual bool Connect ()
 
abstract bool Disconnect ()
 
abstract PhotonSocketError Send (byte[] data, int length)
 
abstract PhotonSocketError Receive (out byte[] data)
 
void HandleReceivedDatagram (byte[] inBuffer, int length, bool willBeReused)
 
bool ReportDebugOfLevel (DebugLevel levelOfMessage)
 
void EnqueueDebugReturn (DebugLevel debugLevel, string message)
 

Public Attributes

bool PollReceive
 
string ConnectAddress
 Address, as defined via a Connect() call. Including protocol, port and or path. More...
 

Protected Member Functions

bool TryParseAddress (string url, out string address, out ushort port, out string urlProtocol, out string urlPath)
 Separates the given address into address (host name or IP) and port. Port must be included after colon! More...
 

Protected Attributes

readonly ConnectionProtocol Protocol
 The protocol for this socket, defined in constructor. More...
 

Properties

IPhotonPeerListener Listener [get]
 
PhotonSocketState State [get, protected set]
 
bool Connected [get]
 
string ServerAddress [get, protected set]
 Contains only the server's hostname (stripped protocol, port and or path). Set in IPhotonSocket.Connect(). More...
 
string ProxyServerAddress [get, protected set]
 
static string ServerIpAddress [get, protected set]
 Contains the IP address of the previously resolved ServerAddress (or empty, if GetIpAddress wasn't used). More...
 
int ServerPort [get, protected set]
 Contains only the server's port address (as string). Set in IphotonSocket.Connect(). More...
 
bool AddressResolvedAsIpv6 [get, set]
 Where available, this exposes if the server's address was resolved into an IPv6 address or not. More...
 
string UrlProtocol [get, protected set]
 
string UrlPath [get, protected set]
 

Constructor & Destructor Documentation

◆ IPhotonSocket()

ExitGames.Client.Photon.IPhotonSocket.IPhotonSocket ( PeerBase  peerBase)
inline

Member Function Documentation

◆ Connect()

virtual bool ExitGames.Client.Photon.IPhotonSocket.Connect ( )
inlinevirtual

◆ Disconnect()

abstract bool ExitGames.Client.Photon.IPhotonSocket.Disconnect ( )
pure virtual

◆ EnqueueDebugReturn()

void ExitGames.Client.Photon.IPhotonSocket.EnqueueDebugReturn ( DebugLevel  debugLevel,
string  message 
)
inline

◆ HandleReceivedDatagram()

void ExitGames.Client.Photon.IPhotonSocket.HandleReceivedDatagram ( byte[]  inBuffer,
int  length,
bool  willBeReused 
)
inline

◆ Receive()

abstract PhotonSocketError ExitGames.Client.Photon.IPhotonSocket.Receive ( out byte[]  data)
pure virtual

◆ ReportDebugOfLevel()

bool ExitGames.Client.Photon.IPhotonSocket.ReportDebugOfLevel ( DebugLevel  levelOfMessage)
inline

◆ Send()

abstract PhotonSocketError ExitGames.Client.Photon.IPhotonSocket.Send ( byte[]  data,
int  length 
)
pure virtual

◆ TryParseAddress()

bool ExitGames.Client.Photon.IPhotonSocket.TryParseAddress ( string  url,
out string  address,
out ushort  port,
out string  urlProtocol,
out string  urlPath 
)
inlineprotected

Separates the given address into address (host name or IP) and port. Port must be included after colon!

This method expects any address to include a port. The final ':' in addressAndPort has to separate it. IPv6 addresses have multiple colons and must use brackets to separate address from port.

Examples: ns.exitgames.com:5058 http://[2001:db8:1f70::999:de8:7648:6e8]:100/

See: http://serverfault.com/questions/205793/how-can-one-distinguish-the-host-and-the-port-in-an-ipv6-url

Member Data Documentation

◆ ConnectAddress

string ExitGames.Client.Photon.IPhotonSocket.ConnectAddress

Address, as defined via a Connect() call. Including protocol, port and or path.

This is set in the constructor and in Connect() again. Typically the address does not change after the IPhotonSocket is instantiated.

◆ PollReceive

bool ExitGames.Client.Photon.IPhotonSocket.PollReceive

◆ Protocol

readonly ConnectionProtocol ExitGames.Client.Photon.IPhotonSocket.Protocol
protected

The protocol for this socket, defined in constructor.

Property Documentation

◆ AddressResolvedAsIpv6

bool ExitGames.Client.Photon.IPhotonSocket.AddressResolvedAsIpv6
getset

Where available, this exposes if the server's address was resolved into an IPv6 address or not.

◆ Connected

bool ExitGames.Client.Photon.IPhotonSocket.Connected
get

◆ Listener

IPhotonPeerListener ExitGames.Client.Photon.IPhotonSocket.Listener
getprotected

◆ ProxyServerAddress

string ExitGames.Client.Photon.IPhotonSocket.ProxyServerAddress
getprotected set

◆ ServerAddress

string ExitGames.Client.Photon.IPhotonSocket.ServerAddress
getprotected set

Contains only the server's hostname (stripped protocol, port and or path). Set in IPhotonSocket.Connect().

◆ ServerIpAddress

string ExitGames.Client.Photon.IPhotonSocket.ServerIpAddress
staticgetprotected set

Contains the IP address of the previously resolved ServerAddress (or empty, if GetIpAddress wasn't used).

◆ ServerPort

int ExitGames.Client.Photon.IPhotonSocket.ServerPort
getprotected set

Contains only the server's port address (as string). Set in IphotonSocket.Connect().

◆ State

PhotonSocketState ExitGames.Client.Photon.IPhotonSocket.State
getprotected set

◆ UrlPath

string ExitGames.Client.Photon.IPhotonSocket.UrlPath
getprotected set

◆ UrlProtocol

string ExitGames.Client.Photon.IPhotonSocket.UrlProtocol
getprotected set

The documentation for this class was generated from the following file: