wut  v1.7.0
Wii U Toolchain
Static Public Member Functions
Server Class Reference

#include <Cafe.h>

Static Public Member Functions

static nn::Result AcceptClient (uint16_t nodeId) asm("AcceptClient__Q4_2nn3dlp4Cafe6ServerSFUs")
 Accepts a client into the DLP child distribution. More...
 
static nn::Result CloseSessions () asm("CloseSessions__Q4_2nn3dlp4Cafe6ServerSFv")
 Closes the DLP session. More...
 
static nn::Result DisconnectClient (uint16_t nodeId) asm("DisconnectClient__Q4_2nn3dlp4Cafe6ServerSFUs")
 Disconnects a client from the DLP session. More...
 
static nn::Result Finalize () asm("Finalize__Q4_2nn3dlp4Cafe6ServerSFv")
 Finalizes DLP. More...
 
static nn::Result GetClientInfo (nn::uds::Cafe::NodeInformation *clientInfo, uint16_t nodeId) asm("GetClientInfo__Q4_2nn3dlp4Cafe6ServerSFPQ4_2nn3uds4Cafe15NodeInformationUs")
 Gets information about a client. More...
 
static nn::Result GetClientState (ClientState *state, uint16_t nodeId) asm("GetClientState__Q4_2nn3dlp4Cafe6ServerSFPQ4_2nn3dlp4Cafe11ClientStateUs")
 Gets a client state. More...
 
static nn::Result GetClientState (ClientState *state, uint32_t *unitsTotal, uint32_t *unitsReceived, uint16_t nodeId) asm("GetClientState__Q4_2nn3dlp4Cafe6ServerSFPQ4_2nn3dlp4Cafe11ClientStatePUiT2Us")
 Gets a client state. More...
 
static nn::Result GetConnectingClients (uint16_t *receivedLength, uint16_t *connectingClients, uint16_t length) asm("GetConnectingClients__Q4_2nn3dlp4Cafe6ServerSFPUsT1Us")
 Gets the clients that are connected to the DLP session. More...
 
static nn::Result GetState (ServerState *state) asm("GetState__Q4_2nn3dlp4Cafe6ServerSFPQ4_2nn3dlp4Cafe11ServerState")
 Gets the server state. More...
 
static nn::Result Initialize (uint8_t maxClientNum, uint32_t uniqueId, uint8_t childIndex, nn::cfg::CTR::UserName *userName) asm("Initialize__Q4_2nn3dlp4Cafe6ServerSFUcUiT1PQ4_2nn3cfg3CTR8UserName")
 Initializes DLP. More...
 
static nn::Result Initialize (bool *dupNoticeNeed, uint8_t maxClientNum, uint32_t uniqueId, uint8_t childIndex, nn::cfg::CTR::UserName *userName) asm("Initialize__Q4_2nn3dlp4Cafe6ServerSFPbUcUiT2PQ4_2nn3cfg3CTR8UserName")
 Initializes DLP. More...
 
static nn::Result OpenSessions (bool isManualAccept, uint8_t channel) asm("OpenSessions__Q4_2nn3dlp4Cafe6ServerSFbUc")
 Opens the DLP session. More...
 
static nn::Result PollStateChange (uint8_t flags) asm("PollStateChange__Q4_2nn3dlp4Cafe6ServerSFUc")
 Checks if the server state chas changed, and waits until it changes if specified. More...
 
static nn::Result RebootAllClients (const char *passPhrase) asm("RebootAllClients__Q4_2nn3dlp4Cafe6ServerSFPCc")
 Reboots all clients into the Download Play child. More...
 
static nn::Result StartDistribution () asm("StartDistribute__Q4_2nn3dlp4Cafe6ServerSFv")
 Starts distribution of the Download Play child. More...
 

Detailed Description

Definition at line 62 of file Cafe.h.

Member Function Documentation

◆ AcceptClient()

static nn::Result AcceptClient ( uint16_t  nodeId)
static

Accepts a client into the DLP child distribution.

Parameters
nodeIdThe node ID of the client.

◆ CloseSessions()

static nn::Result CloseSessions ( )
static

Closes the DLP session.

◆ DisconnectClient()

static nn::Result DisconnectClient ( uint16_t  nodeId)
static

Disconnects a client from the DLP session.

This cannot be done after starting distribution.

Parameters
nodeIdThe node ID of the client.

◆ Finalize()

static nn::Result Finalize ( )
static

Finalizes DLP.

◆ GetClientInfo()

static nn::Result GetClientInfo ( nn::uds::Cafe::NodeInformation clientInfo,
uint16_t  nodeId 
)
static

Gets information about a client.

Parameters
clientInfoPointer where the client information is written.
nodeIdNode ID of the client.

◆ GetClientState() [1/2]

static nn::Result GetClientState ( ClientState state,
uint16_t  nodeId 
)
static

Gets a client state.

Parameters
statePointer where the client state is filled in.
nodeIdNode ID of the client.

◆ GetClientState() [2/2]

static nn::Result GetClientState ( ClientState state,
uint32_t *  unitsTotal,
uint32_t *  unitsReceived,
uint16_t  nodeId 
)
static

Gets a client state.

Parameters
statePointer where the client state is filled in.
unitsTotalPointer filled with the total number of units being distributed. Only filled when starting distribution and the DLP child isn't cached.
unitsReceivedPointer filled with the number of units that the client has received. Only filled when starting distribution and the DLP child isn't cached.
nodeIdNode ID of the client.

◆ GetConnectingClients()

static nn::Result GetConnectingClients ( uint16_t *  receivedLength,
uint16_t *  connectingClients,
uint16_t  length 
)
static

Gets the clients that are connected to the DLP session.

Parameters
receivedLengthPointer where the number of clients written to the array is stored.
connectingClientsArray where the node IDs of the clients are written.
lengthNumber of nodes that the connectingClients array can hold.

◆ GetState()

static nn::Result GetState ( ServerState state)
static

Gets the server state.

Internal states are filtered as Distributing .

Parameters
statePointer where the server state is written.

◆ Initialize() [1/2]

static nn::Result Initialize ( uint8_t  maxClientNum,
uint32_t  uniqueId,
uint8_t  childIndex,
nn::cfg::CTR::UserName userName 
)
static

Initializes DLP.

Parameters
maxClientNumMaximum number of clients allowed for distribution. Must be between 1 and 8 inclusively.
uniqueIdUnique ID of the DLP child to be distributed.
childIndexIndex of the DLP child to be distributed.
userNameUsername that will be displayed to the clients. If NULL, the Mii name will be used.

◆ Initialize() [2/2]

static nn::Result Initialize ( bool *  dupNoticeNeed,
uint8_t  maxClientNum,
uint32_t  uniqueId,
uint8_t  childIndex,
nn::cfg::CTR::UserName userName 
)
static

Initializes DLP.

Parameters
dupNoticeNeedUnknown output bool, always false on the Wii U.
maxClientNumMaximum number of clients allowed for distribution. Must be between 1 and 8 inclusively.
uniqueIdUnique ID of the DLP child to be distributed.
childIndexIndex of the DLP child to be distributed.
userNameUsername that will be displayed to the clients. If NULL, the Mii name will be used.

◆ OpenSessions()

static nn::Result OpenSessions ( bool  isManualAccept,
uint8_t  channel 
)
static

Opens the DLP session.

Parameters
isManualAcceptIf set, all clients must be accepted to allow them to join the session.
channelThe channel to be used for hosting the session. Use 0 to choose a channel automatically. Must be either 0, 1, 6 or 11.

◆ PollStateChange()

static nn::Result PollStateChange ( uint8_t  flags)
static

Checks if the server state chas changed, and waits until it changes if specified.

Parameters
flagsFlags, see PollStateChangeFlags for all flags.

◆ RebootAllClients()

static nn::Result RebootAllClients ( const char *  passPhrase)
static

Reboots all clients into the Download Play child.

Parameters
passPhrasePassphrase to be used by the client when connecting to the main UDS network. If NULL, it will be set to an empty string.

◆ StartDistribution()

static nn::Result StartDistribution ( )
static

Starts distribution of the Download Play child.


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