gpg::StatsManager

#include <stats_manager.h>

Consente di acquisire e impostare vari dati relativi alle statistiche.

Riepilogo

Tipi pubblici

FetchForPlayerCallback typedef
std::function< void(const FetchForPlayerResponse &)>
Definisce un tipo di callback che riceve un FetchForPlayerResponse.

Funzioni pubbliche

FetchForPlayer(FetchForPlayerCallback callback)
void
Carica in modo asincrono tutti i dati statistici relativi al player attualmente connesso.
FetchForPlayer(DataSource data_source, FetchForPlayerCallback callback)
void
Carica in modo asincrono tutti i dati statistici relativi al player attualmente connesso.
FetchForPlayerBlocking()
Carica in modo sincrono tutti i dati delle statistiche per il player attualmente collegato, restituendo direttamente il valore FetchForPlayerResponse.
FetchForPlayerBlocking(DataSource data_source)
Carica in modo sincrono tutti i dati delle statistiche per il player attualmente collegato, restituendo direttamente il valore FetchForPlayerResponse.
FetchForPlayerBlocking(Timeout timeout)
Carica in modo sincrono tutti i dati delle statistiche per il player attualmente collegato, restituendo direttamente il valore FetchForPlayerResponse.
FetchForPlayerBlocking(DataSource data_source, Timeout timeout)
Carica in modo sincrono tutti i dati delle statistiche per il player attualmente collegato, restituendo direttamente il valore FetchForPlayerResponse.

Strutture

gpg::StatsManager::FetchForPlayerResponse

Contiene tutti i dati PlayerStats e lo stato della risposta.

Tipi pubblici

FetchForPlayerCallback

std::function< void(const FetchForPlayerResponse &)> FetchForPlayerCallback

Definisce un tipo di callback che riceve un FetchForPlayerResponse.

Questo tipo di callback viene fornito alle funzioni FetchForPlayer(*) riportate di seguito.

Funzioni pubbliche

FetchForPlayer

void FetchForPlayer(
  FetchForPlayerCallback callback
)

Carica in modo asincrono tutti i dati statistici relativi al player attualmente connesso.

Chiama l'elemento FetchForPlayerCallback fornito al completamento dell'operazione. Se non specifichi data_source, questa chiamata di funzione equivale a chiamare FetchForPlayer(DataSource data_source, FetchForPlayerCallback callback), con data_source specificato come CACHE_OR_NETWORK.

FetchForPlayer

void FetchForPlayer(
  DataSource data_source,
  FetchForPlayerCallback callback
)

Carica in modo asincrono tutti i dati statistici relativi al player attualmente connesso.

Chiama l'elemento FetchForPlayerCallback fornito al completamento dell'operazione. Specifica data_source come CACHE_OR_NETWORK o NETWORK_only.

FetchForPlayerBlocking

FetchForPlayerResponse FetchForPlayerBlocking()

Carica in modo sincrono tutti i dati delle statistiche per il player attualmente collegato, restituendo direttamente il valore FetchForPlayerResponse.

Se non specifichi data_source o timeout, questa chiamata di funzione equivale alla chiamata di FetchForPlayerBlock(DataSource data_source, Timeout timeout) a FetchForPlayerResponse con data_source specificato come CACHE_OR_NETWORK e un timeout specificato su 10 anni.

FetchForPlayerBlocking

FetchForPlayerResponse FetchForPlayerBlocking(
  DataSource data_source
)

Carica in modo sincrono tutti i dati delle statistiche per il player attualmente collegato, restituendo direttamente il valore FetchForPlayerResponse.

Specifica data_source come CACHE_OR_NETWORK o NETWORK_only. Se non specifichi il timeout, questa chiamata di funzione equivale a chiamare il metodo FetchForPlayerBlock(DataSource data_source, Timeout timeout) FetchForPlayerResponse con il valore data_source e il timeout specificati su 10 anni.

FetchForPlayerBlocking

FetchForPlayerResponse FetchForPlayerBlocking(
  Timeout timeout
)

Carica in modo sincrono tutti i dati delle statistiche per il player attualmente collegato, restituendo direttamente il valore FetchForPlayerResponse.

Specifica il timeout come numero arbitrario di millisecondi. Se non specifichi data_source, questa chiamata di funzione equivale a chiamare il metodo FetchForPlayerBlock(DataSource data_source, timeout timeout) di FetchForPlayerResponse con data_source specificato come CACHE_OR_NETWORK e un timeout contenente il valore specificato.

FetchForPlayerBlocking

FetchForPlayerResponse FetchForPlayerBlocking(
  DataSource data_source,
  Timeout timeout
)

Carica in modo sincrono tutti i dati delle statistiche per il player attualmente collegato, restituendo direttamente il valore FetchForPlayerResponse.

Specifica data_source come CACHE_OR_NETWORK o NETWORK_only. Specifica il timeout come numero arbitrario di millisecondi.