nn::nex::Session::QuerySessions Member Function

Syntax

static qBool QuerySessions(
     CallContext * pContext,
     qList< SessionDescription > * pOutputList,
     qBool bFilterMatching = true,
     qUnsignedInt32 uiTimeout = 1000
);

Parameters

Name Description
in pContext Specifies a pointer to the call context used by applications to determine execution status.
out pOutputList Specifies a pointer to a list used to accept descriptors for sessions that have been found.
in bFilterMatching Specifies whether to enumerate sessions holding the same title (true by default).
in uiTimeout Specifies the timeout to use when searching for a session in units of milliseconds (1000 by default).

Return Values



Value Description
true Returned when the call executed successfully. (See the status of pContext regarding whether it actually succeeded.)
false Returned when the call could not execute. SYSTEMERROR_DC_CLUSTER_ALREADY_INITIALIZED is signaled when the station has already joined a session or already created one. SYSTEMERROR_GEN_INVALID_PARAMETER is signaled when a session descriptor could not be found.

Description

Searches for sessions on the LAN.

When connected using a socket, checks whether another process connected to the same access point has opened a session. Using this feature allows you to skip matchmaking operations through a server, and test P2P functionality that utilizes a socket.

This overloaded function returns immediately because it executes asynchronously. (When in user thread mode, this executes when Scheduler::Dispatch is called.) Monitor execution status for the call context specified by pCallContext.

Note: This function was designed for debugging. Do not use this function in product releases.

See Also

JoinSession, CreateSession

Revision History

2012/01/27
Initial version.

CONFIDENTIAL