CTR Pia
4.11.3
Game Communication Engine
|
This is the base class for managing the sending and receiving of events. More...
Public Types | |
typedef u16 | Id |
Specifies the type of the ID for identifying clone elements. | |
Public Member Functions | |
virtual | ~EventCloneElementBase () |
Destroys the object. | |
const CloneBase * | GetCloneBase () const |
Gets the CloneBase this object is registered to. More... | |
Id | GetId () const |
Gets the ID. More... | |
const CloneProtocol * | GetProtocol () const |
Gets the CloneProtocol of the CloneBase this object is registered to. More... | |
size_t | GetUsingBufferNum () const |
Gets the current number of event buffers in use. More... | |
bool | IsDropEvent () const |
Gets whether a drop event error occurred. More... | |
bool | IsReadyToSetValue () const |
Determines whether a value can be set. More... | |
bool | IsRegisteredWithCloneBase () const |
Determines whether the object is registered with CloneBase . More... | |
bool | IsRegisteredWithProtocol () const |
Determines whether the object is registered with CloneProtocol . More... | |
void | Trace (u64 flag) const |
Prints information that is useful for debugging. More... | |
Profiling | |
nn::Result | SetProfiler (CloneProfilerBase *pSendProfiler, CloneProfilerBase *pReceiveProfiler) |
Sets an object to manage send/receive profiling. More... | |
const CloneProfilerBase * | GetSendProfiler () const |
Gets the object configured to manage send profiling. More... | |
const CloneProfilerBase * | GetReceiveProfiler () const |
Gets the object configured to manage receive profiling. More... | |
void | ResetProfiler () |
Resets the results of send/receive profiling. More... | |
u32 | GetProfiledLatestSendCount (StationIndex stationIndex) const |
Gets the send count for the last CloneProfiler::LATEST_BUFFER_SIZE times common::Scheduler::Dispatch was called. More... | |
u32 | GetProfiledLatestSendSize (StationIndex stationIndex) const |
Gets the total amount of data, in bytes, sent during the last CloneProfiler::LATEST_BUFFER_SIZE times of common::Scheduler::Dispatch being called. More... | |
u32 | GetProfiledTotalSendCount (StationIndex stationIndex) const |
Gets the number of times sent since ResetProfiler was called. More... | |
u32 | GetProfiledTotalSendSize (StationIndex stationIndex) const |
Gets the amount of data, in bytes, sent since ResetProfiler was called. More... | |
u32 | GetProfiledLatestReceiveCount (StationIndex stationIndex) const |
Gets the receive count for the last CloneProfiler::LATEST_BUFFER_SIZE times common::Scheduler::Dispatch was called. More... | |
u32 | GetProfiledLatestReceiveSize (StationIndex stationIndex) const |
Gets the total amount of data, in bytes, received during the last CloneProfiler::LATEST_BUFFER_SIZE times of common::Scheduler::Dispatch being called. More... | |
u32 | GetProfiledTotalReceiveCount (StationIndex stationIndex) const |
Gets the number of times received since ResetProfiler was called. More... | |
u32 | GetProfiledTotalReceiveSize (StationIndex stationIndex) const |
Gets the amount of data, in bytes, received since ResetProfiler was called. More... | |
This is the base class for managing the sending and receiving of events.
2014-06-03 Fixed a bug where if the first sent event was dropped, the second event or later events were treated as the first event.
2014-03-12 Added a function that gets the current number of event buffers in use.
2013-07-18 Initial version.
|
inlineinherited |
|
inlineinherited |
|
inherited |
Gets the receive count for the last CloneProfiler::LATEST_BUFFER_SIZE
times common::Scheduler::Dispatch
was called.
[in] | stationIndex | The StationIndex that is subject to profiling. |
CloneProfiler::LATEST_BUFFER_SIZE
times common::Scheduler::Dispatch
was called. Returns 0
if no object is configured to manage receive profiling.
|
inherited |
Gets the total amount of data, in bytes, received during the last CloneProfiler::LATEST_BUFFER_SIZE
times of common::Scheduler::Dispatch
being called.
[in] | stationIndex | The StationIndex that is subject to profiling. |
CloneProfiler::LATEST_BUFFER_SIZE
times of common::Scheduler::Dispatch
being called. Returns 0
if no object is configured to manage receive profiling.
|
inherited |
Gets the send count for the last CloneProfiler::LATEST_BUFFER_SIZE
times common::Scheduler::Dispatch
was called.
[in] | stationIndex | The StationIndex that is subject to profiling. |
CloneProfiler::LATEST_BUFFER_SIZE
times common::Scheduler::Dispatch
was called. Returns 0
if no object is configured to manage send profiling.
|
inherited |
Gets the total amount of data, in bytes, sent during the last CloneProfiler::LATEST_BUFFER_SIZE
times of common::Scheduler::Dispatch
being called.
[in] | stationIndex | The StationIndex that is subject to profiling. |
CloneProfiler::LATEST_BUFFER_SIZE
times of common::Scheduler::Dispatch
being called. Returns 0
if no object is configured to manage send profiling.
|
inherited |
Gets the number of times received since ResetProfiler
was called.
[in] | stationIndex | The StationIndex that is subject to profiling. |
ResetProfiler
was called. Returns 0
if no object is configured to manage receive profiling.
|
inherited |
Gets the amount of data, in bytes, received since ResetProfiler
was called.
[in] | stationIndex | The StationIndex that is subject to profiling. |
ResetProfiler
was called. Returns 0
if no object is configured to manage receive profiling.
|
inherited |
Gets the number of times sent since ResetProfiler
was called.
[in] | stationIndex | The StationIndex that is subject to profiling. |
ResetProfiler
was called. Returns 0
if no object is configured to manage send profiling.
|
inherited |
Gets the amount of data, in bytes, sent since ResetProfiler
was called.
[in] | stationIndex | The StationIndex that is subject to profiling. |
ResetProfiler
was called. Returns 0
if no object is configured to manage send profiling.
|
inherited |
Gets the CloneProtocol
of the CloneBase
this object is registered to.
CloneProtocol
of the CloneBase
this object is registered to.
|
inlineinherited |
Gets the object configured to manage receive profiling.
NULL
if nothing has been set.
|
inlineinherited |
Gets the object configured to manage send profiling.
NULL
if nothing has been set. size_t nn::pia::clone::EventCloneElementBase::GetUsingBufferNum | ( | ) | const |
Gets the current number of event buffers in use.
Sometimes the return value is not zero (0) when it is registered to ReceiveClone
, AtomicSharingClone
, or SequentialSharingClone
. When subsequent data is received, data that can be deleted will be deleted from the buffer.
|
inline |
Gets whether a drop event error occurred.
If a station disconnects abnormally when using AtomicSharingClone
, an event that was supposed to be received may be lost. If this error occurs in any of the EventCloneElement
objects, the CloneProtocol::GetError
function returns CloneProtocol::ERROR_TYPE_DROP_EVENT
.
true
if a drop event error occurred.
|
inherited |
Determines whether a value can be set.
true
if a value can be set.
|
inlineinherited |
|
inherited |
Determines whether the object is registered with CloneProtocol
.
true
if it is registered with CloneProtocol
.
|
inherited |
Resets the results of send/receive profiling.
|
inherited |
Sets an object to manage send/receive profiling.
Clone element send/receive tasks can be profiled by configuring CloneProfiler
. This calculation includes all exchanges of data between this clone element and other clone elements, so the data exchanges between clone elements on the local station are also included in the value.
Even when compression is enabled, the uncompressed size is used in the calculation.
A CloneProfiler
instance that is already configured can be released by specifying NULL
in the arguments.
[in] | pSendProfiler | Specifies the CloneProfiler that manages the send profiling. Specify NULL if not necessary. |
[in] | pReceiveProfiler | Specifies the CloneProfiler that manages the receive profiling. Specify NULL if not necessary. |
Result
value for which the IsSuccess
function returns true
if execution succeeds. You must make sure that the implementation of this function in your application does not return any errors. ResultInvalidArgument
Indicates that an argument is invalid. Programming error. Fix your program so that this error is not returned.void nn::pia::clone::EventCloneElementBase::Trace | ( | u64 | flag | ) | const |
Prints information that is useful for debugging.
[in] | flag | Specifies the bitwise OR of trace flags. For more information, see the TraceFlag type. |