VR-Vantage
Loading...
Searching...
No Matches
ImPool< T > Struct Template Reference
Inheritance diagram for ImPool< T >:

Public Member Functions

 ImPool ()
 ~ImPool ()
T * GetByKey (ImGuiID key)
T * GetByIndex (ImPoolIdx n)
ImPoolIdx GetIndex (const T *p) const
T * GetOrAddByKey (ImGuiID key)
bool Contains (const T *p) const
void Clear ()
T * Add ()
void Remove (ImGuiID key, const T *p)
void Remove (ImGuiID key, ImPoolIdx idx)
void Reserve (int capacity)
int GetAliveCount () const
int GetBufSize () const
int GetMapSize () const
T * TryGetMapData (ImPoolIdx n)
int GetSize ()

Public Attributes

ImVector< T > Buf
ImGuiStorage Map
ImPoolIdx FreeIdx
ImPoolIdx AliveCount

Constructor & Destructor Documentation

◆ ImPool()

template<typename T>
ImPool< T >::ImPool ( )
inline

References AliveCount, and FreeIdx.

◆ ~ImPool()

template<typename T>
ImPool< T >::~ImPool ( )
inline

References Clear().

Member Function Documentation

◆ GetByKey()

template<typename T>
T * ImPool< T >::GetByKey ( ImGuiID key)
inline

References Buf, and Map.

◆ GetByIndex()

template<typename T>
T * ImPool< T >::GetByIndex ( ImPoolIdx n)
inline

References Buf.

Referenced by TryGetMapData().

◆ GetIndex()

template<typename T>
ImPoolIdx ImPool< T >::GetIndex ( const T * p) const
inline

References Buf, and IM_ASSERT.

Referenced by Remove().

◆ GetOrAddByKey()

template<typename T>
T * ImPool< T >::GetOrAddByKey ( ImGuiID key)
inline

References Add(), Buf, FreeIdx, and Map.

◆ Contains()

template<typename T>
bool ImPool< T >::Contains ( const T * p) const
inline

References Buf.

◆ Clear()

template<typename T>
void ImPool< T >::Clear ( )
inline

References AliveCount, Buf, FreeIdx, and Map.

Referenced by ~ImPool().

◆ Add()

template<typename T>
T * ImPool< T >::Add ( )
inline

References AliveCount, Buf, FreeIdx, and IM_PLACEMENT_NEW.

Referenced by GetOrAddByKey().

◆ Remove() [1/2]

template<typename T>
void ImPool< T >::Remove ( ImGuiID key,
const T * p )
inline

References GetIndex(), and Remove().

Referenced by Remove().

◆ Remove() [2/2]

template<typename T>
void ImPool< T >::Remove ( ImGuiID key,
ImPoolIdx idx )
inline

References AliveCount, Buf, FreeIdx, and Map.

◆ Reserve()

template<typename T>
void ImPool< T >::Reserve ( int capacity)
inline

References Buf, and Map.

◆ GetAliveCount()

template<typename T>
int ImPool< T >::GetAliveCount ( ) const
inline

References AliveCount.

◆ GetBufSize()

template<typename T>
int ImPool< T >::GetBufSize ( ) const
inline

References Buf.

◆ GetMapSize()

template<typename T>
int ImPool< T >::GetMapSize ( ) const
inline

References Map.

Referenced by GetSize().

◆ TryGetMapData()

template<typename T>
T * ImPool< T >::TryGetMapData ( ImPoolIdx n)
inline

References GetByIndex(), and Map.

◆ GetSize()

template<typename T>
int ImPool< T >::GetSize ( )
inline

References GetMapSize().

Member Data Documentation

◆ Buf

template<typename T>
ImVector<T> ImPool< T >::Buf

◆ Map

template<typename T>
ImGuiStorage ImPool< T >::Map

◆ FreeIdx

template<typename T>
ImPoolIdx ImPool< T >::FreeIdx

Referenced by Add(), Clear(), GetOrAddByKey(), ImPool(), and Remove().

◆ AliveCount

template<typename T>
ImPoolIdx ImPool< T >::AliveCount

Referenced by Add(), Clear(), GetAliveCount(), ImPool(), and Remove().


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