Photon C++ Client API  5.0.7.3
Public Member Functions | List of all members
TrafficStatsGameLevel Class Reference
Inheritance diagram for TrafficStatsGameLevel:
Inheritance graph
[legend]
Collaboration diagram for TrafficStatsGameLevel:
Collaboration graph
[legend]

Public Member Functions

virtual ~TrafficStatsGameLevel (void)
 
int getOperationByteCount (void) const
 
int getOperationCount (void) const
 
int getResultByteCount (void) const
 
int getResultCount (void) const
 
int getEventByteCount (void) const
 
int getEventCount (void) const
 
int getLongestOpResponseCallback (void) const
 
nByte getLongestOpResponseCallbackOpCode (void) const
 
int getLongestEventCallback (void) const
 
nByte getLongestEventCallbackCode (void) const
 
int getLongestDeltaBetweenDispatching (void) const
 
int getLongestDeltaBetweenSending (void) const
 
int getDispatchIncomingCommandsCalls (void) const
 
int getSendOutgoingCommandsCalls (void) const
 
int getTotalByteCount (void) const
 
int getTotalMessageCount (void) const
 
int getTotalIncomingByteCount (void) const
 
int getTotalIncomingMessageCount (void) const
 
int getTotalOutgoingByteCount (void) const
 
int getTotalOutgoingMessageCount (void) const
 
void resetMaximumCounters (void)
 
virtual Common::JStringtoString (Common::JString &retStr, bool withTypes=false) const
 
virtual Common::JString toStringVitalStats (void) const
 
virtual JStringtoString (JString &retStr, bool withTypes=false) const=0
 
JString toString (bool withTypes=false) const
 
- Public Member Functions inherited from ToString
virtual ~ToString (void)
 
virtual JString typeToString (void) const
 
JString toString (bool withTypes=false) const
 

Detailed Description

This class provides game level traffic statistics.

See also
PhotonPeer::getTrafficStatsEnabled(), PhotonPeer::setTrafficStatsEnabled(), PhotonPeer::getTrafficStatsElapsedMs(), PhotonPeer::getTrafficStatsGameLevel()

Constructor & Destructor Documentation

◆ ~TrafficStatsGameLevel()

~TrafficStatsGameLevel ( void  )
virtual

Destructor.

Member Function Documentation

◆ getOperationByteCount()

int getOperationByteCount ( void  ) const
Returns
the sum of outgoing operations in bytes

◆ getOperationCount()

int getOperationCount ( void  ) const
Returns
the count of outgoing operations.

◆ getResultByteCount()

int getResultByteCount ( void  ) const
Returns
the sum of byte-cost of incoming operation-results.

◆ getResultCount()

int getResultCount ( void  ) const
Returns
the count of incoming operation-results.

◆ getEventByteCount()

int getEventByteCount ( void  ) const
Returns
the sum of byte-cost of incoming events.

◆ getEventCount()

int getEventCount ( void  ) const
Returns
the count of incoming events.

◆ getLongestOpResponseCallback()

int getLongestOpResponseCallback ( void  ) const
Note
If such a callback takes long, it will lower the network performance and might lead to timeouts.
Returns
the longest time it took to complete a call to OnOperationResponse (in your code).

◆ getLongestOpResponseCallbackOpCode()

nByte getLongestOpResponseCallbackOpCode ( void  ) const
Returns
the OperationCode that causes the LongestOpResponseCallback. See that description.

◆ getLongestEventCallback()

int getLongestEventCallback ( void  ) const
Note
If such a callback takes long, it will lower the network performance and might lead to timeouts.
Returns
the longest time a call to OnEvent (in your code) took.

◆ getLongestEventCallbackCode()

nByte getLongestEventCallbackCode ( void  ) const
Returns
the EventCode that caused the LongestEventCallback. See that description.

◆ getLongestDeltaBetweenDispatching()

int getLongestDeltaBetweenDispatching ( void  ) const
Note
This is not a crucial timing for networking. Long gaps just add "local lag" to events that are available already.
Returns
the longest time between subsequent calls to PhotonPeer::dispatchIncomingCommands() in milliseconds.

◆ getLongestDeltaBetweenSending()

int getLongestDeltaBetweenSending ( void  ) const
Note
This is a crucial value for network stability. Without calling PhotonPeer::sendOutgoingCommands(), nothing will be sent to the server, which might time out this client.
Returns
the longest time between subsequent calls to PhotonPeer::sendOutgoingCommands() in milliseconds.

◆ getDispatchIncomingCommandsCalls()

int getDispatchIncomingCommandsCalls ( void  ) const
Returns
the number of calls of PhotonPeer::dispatchIncomingCommands().

◆ getSendOutgoingCommandsCalls()

int getSendOutgoingCommandsCalls ( void  ) const
Returns
the number of calls of PhotonPeer::sendOutgoingCommands().

◆ getTotalByteCount()

int getTotalByteCount ( void  ) const
Returns
the sum of byte-cost of all "logic level" messages.

◆ getTotalMessageCount()

int getTotalMessageCount ( void  ) const
Returns
the sum of counted "logic level" messages.

◆ getTotalIncomingByteCount()

int getTotalIncomingByteCount ( void  ) const
Returns
the sum of byte-cost of all incoming "logic level" messages.

◆ getTotalIncomingMessageCount()

int getTotalIncomingMessageCount ( void  ) const
Returns
the sum of counted incoming "logic level" messages.

◆ getTotalOutgoingByteCount()

int getTotalOutgoingByteCount ( void  ) const
Returns
the sum of byte-cost of all outgoing "logic level" messages (= OperationByteCount).

◆ getTotalOutgoingMessageCount()

int getTotalOutgoingMessageCount ( void  ) const
Returns
the sum of counted outgoing "logic level" messages (= OperationCount).

◆ resetMaximumCounters()

void resetMaximumCounters ( void  )

Resets the values that can be maxed out, like LongestDeltaBetweenDispatching. See remarks.

Set to 0: LongestDeltaBetweenDispatching, LongestDeltaBetweenSending, LongestEventCallback, LongestEventCallbackCode, LongestOpResponseCallback, LongestOpResponseCallbackOpCode. Also resets internal values: mTimeOfLastDispatchCall and mTimeOfLastSendCall (so intervals are tracked correctly).

◆ toString() [1/3]

JString & toString ( Common::JString retStr,
bool  withTypes = false 
) const
virtual
Remarks
The cost of this function depends a lot on implementation details of the implementing subclasses, but for container classes this function can become quite expensive, if the instance contains huge amounts of data, as its cost for many container class implementations increases disproportionately high to the size of the payload.
Parameters
retStrreference to a string, to store the return-value in; the information, which is generated by this function, will be attached at the end of any eventually existing previous content of the string
withTypesset to true, to include type information in the generated string
Returns
a JString representation of the instance and its contents for debugging purposes.

Implements ToString.

◆ toStringVitalStats()

JString toStringVitalStats ( void  ) const
virtual
Returns
a JString representation of the vital stats for debugging purposes.

◆ toString() [2/3]

toString
Remarks
The cost of this function depends a lot on implementation details of the implementing subclasses, but for container classes this function can become quite expensive, if the instance contains huge amounts of data, as its cost for many container class implementations increases disproportionately high to the size of the payload.
Parameters
retStrreference to a string, to store the return-value in; the information, which is generated by this function, will be attached at the end of any eventually existing previous content of the string
withTypesset to true, to include type information in the generated string
Returns
a JString representation of the instance and its contents for debugging purposes.

◆ toString() [3/3]

JString toString

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Parameters
withTypesset to true, to include type information in the generated string
Returns
a JString representation of the instance and its contents for debugging purposes.
See also
JString