Pyrogenesis HEAD
Pyrogenesis, a RTS Engine
CUserReporter Class Reference

#include <UserReport.h>

Collaboration diagram for CUserReporter:

Public Member Functions

 CUserReporter ()
 
 ~CUserReporter ()
 
void Initialize ()
 
void Deinitialize ()
 
void Update ()
 Must be called frequently (preferably every frame), to update some internal reconnection timers. More...
 
bool IsReportingEnabled ()
 
void SetReportingEnabled (bool enabled)
 
std::string GetStatus ()
 
void SubmitReport (const std::string &type, int version, const std::string &data, const std::string &dataHumanReadable)
 Submit a report to be transmitted to the online server. More...
 

Private Member Functions

std::string LoadUserID ()
 

Private Attributes

CUserReporterWorkerm_Worker
 

Constructor & Destructor Documentation

◆ CUserReporter()

CUserReporter::CUserReporter ( )

◆ ~CUserReporter()

CUserReporter::~CUserReporter ( )

Member Function Documentation

◆ Deinitialize()

void CUserReporter::Deinitialize ( )

◆ GetStatus()

std::string CUserReporter::GetStatus ( )

◆ Initialize()

void CUserReporter::Initialize ( )

◆ IsReportingEnabled()

bool CUserReporter::IsReportingEnabled ( )

◆ LoadUserID()

std::string CUserReporter::LoadUserID ( )
private

◆ SetReportingEnabled()

void CUserReporter::SetReportingEnabled ( bool  enabled)

◆ SubmitReport()

void CUserReporter::SubmitReport ( const std::string &  type,
int  version,
const std::string &  data,
const std::string &  dataHumanReadable 
)

Submit a report to be transmitted to the online server.

Nothing will be transmitted until reporting is enabled by the user, so you don't need to check for that first.

Parameters
typeshort string identifying the type of data ("hwdetect", "message", etc)
versionpositive integer that should be incremented if the data is changed in a non-compatible way and the server will have to distinguish old and new formats
datathe actual data (typically UTF-8-encoded text, or JSON, but could be binary)
dataHumanReadablean optional, readable representation of the same data, allowing users to assess for privacy concerns

◆ Update()

void CUserReporter::Update ( )

Must be called frequently (preferably every frame), to update some internal reconnection timers.

Member Data Documentation

◆ m_Worker

CUserReporterWorker* CUserReporter::m_Worker
private

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