sead
Loading...
Searching...
No Matches
sead::FixedTreeMap< Key, Value, N > Class Template Reference

#include <seadTreeMap.h>

Inherits sead::TreeMap< Key, Value >.

Public Member Functions

 FixedTreeMap ()
void allocBuffer (s32 node_max, s32 alignment=cDefaultAlignment)=delete
void allocBuffer (s32 node_max, Heap *heap, s32 alignment=cDefaultAlignment)=delete
bool tryAllocBuffer (s32 node_max, s32 alignment=cDefaultAlignment)=delete
bool tryAllocBuffer (s32 node_max, Heap *heap, s32 alignment=cDefaultAlignment)=delete
void freeBuffer ()=delete
void setBuffer (s32 node_max, void *buf)=delete
Public Member Functions inherited from sead::TreeMap< Key, Value >
 TreeMap ()
void allocBuffer (s32 node_max, s32 alignment=cDefaultAlignment)
void allocBuffer (s32 node_max, Heap *heap, s32 alignment=cDefaultAlignment)
bool tryAllocBuffer (s32 node_max, s32 alignment=cDefaultAlignment)
bool tryAllocBuffer (s32 node_max, Heap *heap, s32 alignment=cDefaultAlignment)
void freeBuffer ()
void setBuffer (s32 node_max, void *buf)
bool isBufferReady () const
bool isEmpty () const
bool isFull () const
s32 size () const
s32 getSize () const
s32 maxSize () const
Value * find (const Key &key) const
bool contains (const Key &key) const
Value * insert (const Key &key)
Value * insert (const Key &key, const Value &value)
void clear ()
template<typename T>
void forEach (const T &fun) const
Public Member Functions inherited from sead::TreeMapImpl< TreeMapKeyImpl< Key > >
 TreeMapImpl ()
void insert (Node *node)
void erase (const Key &key)
Nodefind (const Key &key) const
bool contains (const Key &key) const
void forEach (const T &fun) const

Protected Attributes

u8 mWork [N *sizeof(typename TreeMap< Key, Value >::Node)]
Protected Attributes inherited from sead::TreeMap< Key, Value >
FreeList mFreeList
s32 mSize
s32 mNodeMax
Protected Attributes inherited from sead::TreeMapImpl< TreeMapKeyImpl< Key > >
NodemRoot

Additional Inherited Members

Public Types inherited from sead::TreeMapImpl< TreeMapKeyImpl< Key > >
typedef TreeMapNode< Key > Node
Static Public Member Functions inherited from sead::TreeMapImpl< TreeMapKeyImpl< Key > >
static Nodemin (Node *h)
static NodeeraseMin (Node *h)
static NodemoveRedLeft (Node *h)
static NodemoveRedRight (Node *h)
static NodefixUp (Node *h)
static NoderotateLeft (Node *h)
static NoderotateRight (Node *h)
static void flipColors (Node *h)
static bool isRed (Node *h)
Protected Member Functions inherited from sead::TreeMap< Key, Value >
void eraseNode_ (Node *node)
void eraseNodeForClear_ (TreeMapNode< TreeMapKeyImpl< Key > > *n)

Constructor & Destructor Documentation

◆ FixedTreeMap()

template<typename Key, typename Value, s32 N>
sead::FixedTreeMap< Key, Value, N >::FixedTreeMap ( )
inline

Member Function Documentation

◆ allocBuffer() [1/2]

template<typename Key, typename Value, s32 N>
void sead::FixedTreeMap< Key, Value, N >::allocBuffer ( s32 node_max,
s32 alignment = cDefaultAlignment )
delete

◆ allocBuffer() [2/2]

template<typename Key, typename Value, s32 N>
void sead::FixedTreeMap< Key, Value, N >::allocBuffer ( s32 node_max,
Heap * heap,
s32 alignment = cDefaultAlignment )
delete

◆ tryAllocBuffer() [1/2]

template<typename Key, typename Value, s32 N>
bool sead::FixedTreeMap< Key, Value, N >::tryAllocBuffer ( s32 node_max,
s32 alignment = cDefaultAlignment )
delete

◆ tryAllocBuffer() [2/2]

template<typename Key, typename Value, s32 N>
bool sead::FixedTreeMap< Key, Value, N >::tryAllocBuffer ( s32 node_max,
Heap * heap,
s32 alignment = cDefaultAlignment )
delete

◆ freeBuffer()

template<typename Key, typename Value, s32 N>
void sead::FixedTreeMap< Key, Value, N >::freeBuffer ( )
delete

◆ setBuffer()

template<typename Key, typename Value, s32 N>
void sead::FixedTreeMap< Key, Value, N >::setBuffer ( s32 node_max,
void * buf )
delete

Member Data Documentation

◆ mWork

template<typename Key, typename Value, s32 N>
u8 sead::FixedTreeMap< Key, Value, N >::mWork[N *sizeof(typename TreeMap< Key, Value >::Node)]
protected