#include <Context.hh>
Contexts can be used to restore a previous memory state for the current session.
Contexts can be thought of like savestates, where we can save and load a given checkpoint. Contexts work by performing a memcpy of the entire game heap, which is reliable since we override operator new with an EGG::Heap implementation. Because the location of certain singletons could change per-race, we also have to capture them in the Context.
Definition at line 59 of file Context.hh.
Classes | |
| struct | Pointers |
Public Member Functions | |
| Context (const Context &c) | |
| Context (Context &&c) | |
| Move constructs Context by stealing the memory block and ptrs from the provided context. | |
| Context & | operator= (const Context &rhs) |
| Context & | operator= (Context &&rhs) |
| bool | operator== (const Context &rhs) const |
Static Public Member Functions | |
| static void | SetActiveContext (const Context &rhs) |
Private Attributes | |
| void * | m_contextMemory |
| Pointers | m_ptrs |
| Host::Context::Context | ( | ) |
Definition at line 22 of file Context.cc.
| Host::Context::Context | ( | const Context & | c | ) |
Definition at line 50 of file Context.cc.
| Host::Context::Context | ( | Context && | c | ) |
Move constructs Context by stealing the memory block and ptrs from the provided context.
Definition at line 58 of file Context.cc.
| Host::Context::~Context | ( | ) |
Definition at line 65 of file Context.cc.
Definition at line 69 of file Context.cc.
Definition at line 81 of file Context.cc.
| bool Host::Context::operator== | ( | const Context & | rhs | ) | const |
Definition at line 91 of file Context.cc.
|
static |
Definition at line 117 of file Context.cc.
|
private |
Definition at line 98 of file Context.hh.
|
private |
Definition at line 99 of file Context.hh.