Cuberite
A lightweight, fast and extensible game server for Minecraft
Public Member Functions | Protected Member Functions | Protected Attributes | Private Types | List of all members
cMojangAPI::cUpdateThread Class Reference
Inheritance diagram for cMojangAPI::cUpdateThread:
Inheritance graph
[legend]
Collaboration diagram for cMojangAPI::cUpdateThread:
Collaboration graph
[legend]

Public Member Functions

 cUpdateThread (cMojangAPI &a_MojangAPI)
 
virtual ~cUpdateThread () override
 
- Public Member Functions inherited from cIsThread
 cIsThread (const AString &a_ThreadName)
 
bool IsCurrentThread (void) const
 Returns true if the thread calling this function is the thread contained within this object. More...
 
bool Start (void)
 Starts the thread; returns without waiting for the actual start. More...
 
void Stop (void)
 Signals the thread to terminate and waits until it's finished. More...
 
bool Wait (void)
 Waits for the thread to finish. More...
 
virtual ~cIsThread ()
 

Protected Member Functions

virtual void Execute (void) override
 This is the main thread entrypoint. More...
 

Protected Attributes

cEvent m_evtNotify
 The event used for notifying that the thread should terminate, as well as timing. More...
 
cMojangAPIm_MojangAPI
 The cMojangAPI instance to update. More...
 
- Protected Attributes inherited from cIsThread
std::atomic< bool > m_ShouldTerminate
 The overriden Execute() method should check this value periodically and terminate if this is true. More...
 

Private Types

typedef cIsThread super
 

Detailed Description

Definition at line 231 of file MojangAPI.cpp.

Member Typedef Documentation

Definition at line 234 of file MojangAPI.cpp.

Constructor & Destructor Documentation

cMojangAPI::cUpdateThread::cUpdateThread ( cMojangAPI a_MojangAPI)
inline

Definition at line 236 of file MojangAPI.cpp.

virtual cMojangAPI::cUpdateThread::~cUpdateThread ( )
inlineoverridevirtual

Definition at line 242 of file MojangAPI.cpp.

Member Function Documentation

virtual void cMojangAPI::cUpdateThread::Execute ( void  )
inlineoverrideprotectedvirtual

This is the main thread entrypoint.

This function, overloaded by the descendants, is called in the new thread.

Implements cIsThread.

Definition at line 262 of file MojangAPI.cpp.

Member Data Documentation

cEvent cMojangAPI::cUpdateThread::m_evtNotify
protected

The event used for notifying that the thread should terminate, as well as timing.

Definition at line 258 of file MojangAPI.cpp.

cMojangAPI& cMojangAPI::cUpdateThread::m_MojangAPI
protected

The cMojangAPI instance to update.

Definition at line 255 of file MojangAPI.cpp.


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