CTR Pia  4.11.3
Game Communication Engine
nn::pia Namespace Reference

Represents the namespace for the Pia API. More...

Namespaces

 chat
 Represents the PiaChat namespace.
 
 clone
 Represents the PiaClone namespace.
 
 common
 Represents the PiaCommon namespace.
 
 inet
 Represents the PiaInet namespace.
.
 
 local
 Represents the PiaLocal namespace.
 
 reckoning
 Represents the PiaReckoning namespace.
 
 session
 Represents the PiaSession namespace.
 
 sync
 Represents the PiaSync namespace.
 
 transport
 Represents the PiaTransport namespace.
 
 util
 Represents the PiaUtil namespace.
 

Classes

class  ResultAllocationFailed
 Indicates a failure to allocate memory or other resources. Applications must be implemented to ensure this Result value is never returned. More...
 
class  ResultAlreadyExists
 Indicates that the object already exists. More...
 
class  ResultAlreadyInitialized
 Indicates that initialization is already complete. Applications must be implemented to ensure this Result value is never returned. More...
 
class  ResultBrokenData
 Indicates that data coming in through the communication line is corrupted or may have been tampered with. More...
 
class  ResultBufferIsFull
 Indicates that the action failed because the buffer required for the action was temporarily full. This may be caused by network congestion. It may succeed if you try again after some time has passed. More...
 
class  ResultBufferShortage
 Indicates that the buffer passed as an argument is too small. Applications must be implemented to ensure this Result value is never returned. More...
 
class  ResultCancelled
 Indicates that the asynchronous process received a cancellation request. More...
 
class  ResultCompanionStationDenied
 Attempted to specify companion stations for the joint session that rejected join-in. More...
 
class  ResultCompanionStationIsLeft
 Attempted to specify companion stations for the joint session that were disconnected. More...
 
class  ResultCompanionStationIsOffline
 (For joint sessions) Attempted to add a station that was not logged in to the server. More...
 
class  ResultConnectionFailed
 Indicates that connecting to the network failed for some reason. (System error.) This result never gets back to the application. More...
 
class  ResultContainerIsFull
 Indicates that the container is full. More...
 
class  ResultCreateStationFailed
 Indicates that the new Station could not be created. (System error.) This result never gets back to the application. More...
 
class  ResultDataIsNotArrivedYet
 Data has not yet arrived from all stations. More...
 
class  ResultDataIsNotSet
 The data to send has not been specified. More...
 
class  ResultDeniedByParticipants
 The local station is blacklisted by a user in the session. More...
 
class  ResultDifferentVersion
 Indicates that the local network version or the application version of the target network is different from that of the local station. More...
 
class  ResultDnsFailed
 Indicates that DNS resolution failed. More...
 
class  ResultErrorOccurred
 Indicates that an internal error occurred. More...
 
class  ResultFailedCreateProtocol
 Failed to generate the system protocol. More...
 
class  ResultFailedStartupProtocol
 Failed to start the system protocol. More...
 
class  ResultGameServerMaintenance
 The game server is down for maintenance. More...
 
class  ResultGameServerProcessAborted
 The game server process aborted. More...
 
class  ResultHostIsNotFriend
 Attempted to join a session with a host that is not a friend. More...
 
class  ResultHostMigrationFailure
 Indicates that local network host migration failed. Hosts leaving the network must be handled appropriately or communication cannot continue. More...
 
class  ResultIncompatibleFormat
 Represents incompatible formats. More...
 
class  ResultInProgress
 Result code indicating that the specified process is already in progress. More...
 
class  ResultInvalidArgument
 Indicates that an invalid argument was passed to an API function. One case where this result would be returned is when a NULL pointer was passed to a function. Applications must be implemented to ensure this Result value is never returned. More...
 
class  ResultInvalidConnection
 Indicates that the connection state is invalid or that wireless mode is off. More...
 
class  ResultInvalidNetwork
 Indicates that a the system cannot connect to this network. More...
 
class  ResultInvalidNode
 Indicates that the node being sent to could not be found on the network. More...
 
class  ResultInvalidState
 Indicates that the API function was called at the wrong time. Indicates that the Pia library was not in the correct state to call the function that returned this Result value. More...
 
class  ResultInvalidSystemMessage
 An invalid message was returned as a response to a join request. More...
 
class  ResultInvalidTiming
 Indicates that the action could not execute because of a timing problem. More...
 
class  ResultJoinRequestDenied
 The join request was rejected by the session host. More...
 
class  ResultMatchmakeSessionIsFull
 Attempted to join a matchmaking session that is full. More...
 
class  ResultMemoryLeak
 Result code indicating that there may be a memory leak in the Pia library. More...
 
class  ResultMeshConnectionIsLost
 The mesh is disconnected. More...
 
class  ResultMeshIsFull
 Could not join the requested mesh because it was full. More...
 
class  ResultMessageNotHandled
 Could not process the received ProtocolMessageOld object. More...
 
class  ResultNatCheckFailed
 Indicates that the NAT check failed. More...
 
class  ResultNatTraversalFailedBothEdm
 NAT traversal between stations failed. The NAT type for both local and remote stations is EDM. More...
 
class  ResultNatTraversalFailedBothEim
 NAT traversal between stations failed. The NAT type for both local and remote stations is EIM. More...
 
class  ResultNatTraversalFailedLocalEdmRemoteEim
 NAT traversal between stations failed. The NAT type was EDM for the local station and EIM for the remote station. More...
 
class  ResultNatTraversalFailedLocalEimRemoteEdm
 NAT traversal between stations failed. The NAT type was EIM for the local station and EDM for the remote station. More...
 
class  ResultNatTraversalRequestTimeout
 NAT traversal between stations failed. The NAT traversal request timed out. More...
 
class  ResultNegligibleFault
 Indicates an error that can be ignored. More...
 
class  ResultNetworkConnectionIsLost
 Indicates that the connection was already terminated. More...
 
class  ResultNetworkIsFull
 The network is full. More...
 
class  ResultNexInternalError
 Indicates that an error occurred in NEX. More...
 
class  ResultNoData
 Indicates that the data was not found. More...
 
class  ResultNotFound
 Indicates that the requested item was not found. More...
 
class  ResultNotFoundNetwork
 Indicates that the network was not found. More...
 
class  ResultNothingPacket
 Indicates that packets expected to be received could not be found. More...
 
class  ResultNotImplemented
 Indicates that a feature is not implemented. Applications must be implemented to ensure this Result value is never returned. More...
 
class  ResultNotInCommunication
 Not currently in communication. More...
 
class  ResultNotInitialized
 Indicates that the object or module that called the function is not initialized. Applications must be implemented to ensure this Result value is never returned. More...
 
class  ResultNotSet
 Result code indicating that values that are supposed to be set in advance are not set. More...
 
class  ResultParticipantInBlackList
 A user on the local station's blacklist is in the session. More...
 
class  ResultRelayFailedNoCandidate
 The relay connection failed. (There was no relay candidate.) More...
 
class  ResultRelayFailedRelayNumLimit
 The relay connection failed. (The limit on the number of relays was exceeded.) More...
 
class  ResultRelayFailedRttLimit
 The relay connection failed. (The RTT limit was exceeded.) More...
 
class  ResultRelayFailedUnknown
 The relay connection failed. (Details unknown.) More...
 
class  ResultSessionConnectionIsLost
 The session was disconnected. More...
 
class  ResultSessionInconsistentState
 There is an inconsistent state in the session. More...
 
class  ResultSessionInvalidState
 The Session API is being called in the wrong way. More...
 
class  ResultSessionIsClosed
 Attempted to join a session that is closed. More...
 
class  ResultSessionIsNotFound
 The session no longer exists. More...
 
class  ResultSessionMigrationFailed
 Processes failed that were necessary for session transitions in joint sessions. More...
 
class  ResultSessionSystemPasswordUnmatch
 Attempted to join a session set with a system password, but the system password did not match. More...
 
class  ResultSessionUserPasswordUnmatch
 Attempted to join a session set with a user password, but the user password did not match. More...
 
class  ResultSessionWrongState
 The state of the joined session was irregular. More...
 
class  ResultStationConnectionFailed
 Failed to connect stations. More...
 
class  ResultStationConnectionNatTraversalFailedEdm
 NAT traversal between stations failed. The NAT type is EDM. (Removed.) More...
 
class  ResultStationConnectionNatTraversalFailedEim
 NAT traversal between stations failed. The NAT type is EIM. (Removed.) More...
 
class  ResultStationConnectionNatTraversalFailedUnknown
 NAT traversal between stations failed. The NAT type is unknown. More...
 
class  ResultTableIsFull
 Indicates that no more entries can be added because the table is full. (System error.) This result never gets back to the application. More...
 
class  ResultTemporaryUnavailable
 Result code that indicates that the API is temporarily unusable. More...
 
class  ResultTimeOut
 Indicates that an asynchronous process timed out. More...
 
struct  StationId
 Definition of the StationId identifying the station within the session. More...
 

Enumerations

Functions

const StationIdGetStationIdAll ()
 Gets the const reference indicating the StationId object to specify all session participants when sending and receiving data. You can also use the STATION_ID_ALL macro.
 
const StationIdGetStationIdHost ()
 Gets the const reference of the StationId object representing the host StationId. You can also use the STATION_ID_HOST macro.
 
const StationIdGetStationIdInvalid ()
 Gets the const reference of the StationId object representing the invalid StationId. You can also use the STATION_ID_INVALID macro.
 

Variables

const size_t MAX_STATION_NUM = 12
 The maximum value for the number of stations that can participate in a Pia session.
 
const u64 STATION_ID_ALL_VALUE = 0xFFFFFFFFFFFFFFFF
 Value indicating StationId for all participants.
 
const u64 STATION_ID_HOST_VALUE = 0xFFFFFFFFFFFFFFFE
 Value indicating host StationId.
 
const u64 STATION_ID_INVALID_VALUE = 0xFFFFFFFFFFFFFFFD
 Value indicating invalid StationId.
 

Detailed Description

Represents the namespace for the Pia API.

Most of the functions in the Pia API are not thread-safe. Do not take it as a guarantee that a function will be thread-safe if nothing is written about it being either thread-safe or not thread-safe in its specific entry within the API Reference. (We will note thread-safe functions in future revisions to the documentation.)


Revision History:

2014-10-29 Added ResultNexInternalError.

2014-09-12 Added ResultSessionConnectionIsLost, ResultInProgress, and ResultNotSet.

2014-09-11 Consolidated all of the Pia Results into this header file.

2014-07-16 Added ResultTemporaryUnavailable.

2013-03-26 Added MODULE_TYPE_DB.

2012-07-25 The NN_PIA_ENABLE_TRACE macro is now also set to a valid value in Development builds.

2012-07-18 Added information about DESCRIPTION_BUFFER_IS_FULL and ResultBufferIsFull.

2012-07-12 Added MODULE_TYPE_UTIL.

2012-07-10 Deleted old Result definitions that had been kept for compatibility.

2012-04-05 Merged generic Result values used in each module. They are now defined in the nn::pia namespace.

2011-11-17 Excluding some exceptions, noted that the Pia API is not guaranteed to be thread-safe.

2011-11-14 Expanded on the documentation of ModuleType and ErrorSeverity.

2011-11-08 Created a page for the nn::pia namespace.

Enumeration Type Documentation

Enumerates modules in the Pia library. You get one of these values when you pass a nn::Result value to the nn::pia::common::ErrorHandler::GetModuleTypeFromResult function. Use this value to determine the module in which an error occurred.

Enumerator
MODULE_TYPE_RESERVED 

Reserved value. The GetModuleTypeFromResult function never returns this value.

MODULE_TYPE_PIA 

Represents a generic Result value.

MODULE_TYPE_COMMON 

Represents a PiaCommon Result value.

MODULE_TYPE_LOCAL 

Represents a PiaLocal Result value.

MODULE_TYPE_TRANSPORT 

Represents a PiaTransport Result value.

MODULE_TYPE_SYNC 

Represents a PiaSync Result value.

MODULE_TYPE_INET 

Represents a PiaInet Result value.

MODULE_TYPE_SESSION 

Represents a PiaSession Result value.

MODULE_TYPE_UTIL 

Represents a PiaUtil Result value.

MODULE_TYPE_SERVICE 

Represents a PiaService Result value.

MODULE_TYPE_DB 

Represents a PiaDB Result value.

MODULE_TYPE_CHAT 

Represents a PiaChat Result value.

MODULE_TYPE_CLONE 

Represents a PiaClone Result value.

MODULE_TYPE_RECKONING 

Represents a PiaReckonng Result value.

MODULE_TYPE_BRAIN 

Represents a PiaBrain Result value.

MODULE_TYPE_UNKNOWN 

Indicates that a Pia module is not the source.

MODULE_TYPE_MAX 

The maximum value. The application is not required to use this value.

Enumerates StationIndex values.

The Pia modules use StationIndex as a station identifier within the session regardless of the network type. IDs were created with the intention of having the application handle information from each station as an array.

The maximum value changes whenever the maximum number of simultaneous connections that the Pia library can support changes.


Revision History:

2013-02-01 Changed STATION_INDEX_MAX and MAX_STATION_NUM to 12 to match the maximum number of simultaneous connection supported by the Pia library.

2012-04-05 Moved from the nn::pia::common namespace to the nn::pia namespace.

Enumerator
STATION_INDEX_1 

ID indicating Player 1.

STATION_INDEX_2 

ID indicating Player 2.

STATION_INDEX_3 

ID indicating Player 3.

STATION_INDEX_4 

ID indicating Player 4.

STATION_INDEX_5 

ID indicating Player 5.

STATION_INDEX_6 

ID indicating Player 6.

STATION_INDEX_7 

ID indicating Player 7.

STATION_INDEX_8 

ID indicating Player 8.

STATION_INDEX_9 

ID indicating Player 9.

STATION_INDEX_10 

ID indicating Player 10.

STATION_INDEX_11 

ID indicating Player 11.

STATION_INDEX_12 

ID indicating Player 12.

STATION_INDEX_MAX 

Maximum value of StationIndex.

STATION_INDEX_INVALID 

ID indicating a station that is not present in the session.

STATION_INDEX_HOST 

ID indicating the station that holds the role of host.

STATION_INDEX_ALL 

ID indicating all stations in the session.