3Depict
|
A class to manage "tear-off" ID values, to allow for indexing without knowing position. More...
#include <basics.h>
Public Member Functions | |
unsigned int | genId (unsigned int position) |
Generate a unique ID value, storing the position ID pair. More... | |
void | killByPos (unsigned int position) |
Remove a uniqueID using its position. More... | |
unsigned int | getPos (unsigned int id) const |
Get the position from its unique ID. More... | |
unsigned int | getId (unsigned int pos) const |
Get the uniqueID from the position. More... | |
void | getIds (std::vector< unsigned int > &idvec) const |
Get all unique IDs. More... | |
void | clear () |
Clear the mapping. More... | |
unsigned int | size () const |
Get the number of elements stored. More... | |
A class to manage "tear-off" ID values, to allow for indexing without knowing position.
void UniqueIDHandler::clear | ( | ) |
Clear the mapping.
Referenced by Scene::clearEffects(), and StashDialog::OnTreeSelChange().
unsigned int UniqueIDHandler::genId | ( | unsigned int | position | ) |
Generate a unique ID value, storing the position ID pair.
References ASSERT.
Referenced by Scene::addEffect().
unsigned int UniqueIDHandler::getId | ( | unsigned int | pos | ) | const |
Get the uniqueID from the position.
References ASSERT.
void UniqueIDHandler::getIds | ( | std::vector< unsigned int > & | idvec | ) | const |
Get all unique IDs.
unsigned int UniqueIDHandler::getPos | ( | unsigned int | id | ) | const |
Get the position from its unique ID.
References ASSERT.
Referenced by Scene::removeEffect().
void UniqueIDHandler::killByPos | ( | unsigned int | position | ) |
Remove a uniqueID using its position.
Referenced by Scene::removeEffect().
|
inline |
Get the number of elements stored.
References getAvailRAM(), getFilesize(), getTotalRAM(), isNotDirectory(), and rmFile().
Referenced by Scene::addEffect().