VisuTwin Canvas
C++ 3D Engine — Metal Backend
Loading...
Searching...
No Matches
visutwin::canvas::SortedLoopArray< T > Class Template Reference

#include <core/sortedLoopArray.h>

Public Member Functions

void append (const T &item)
void insert (const T &item)
void remove (const T &item)
void sort ()
 SortedLoopArray (const SortedLoopArrayOptions< T > &options)
 SortedLoopArray (std::function< float(const T &)> keyExtractor)

Public Attributes

std::vector< T > items
size_t length = 0
int loopIndex = -1

Detailed Description

template<typename T>
class visutwin::canvas::SortedLoopArray< T >

Definition at line 18 of file sortedLoopArray.h.

Constructor & Destructor Documentation

◆ SortedLoopArray() [1/2]

template<typename T>
visutwin::canvas::SortedLoopArray< T >::SortedLoopArray ( const SortedLoopArrayOptions< T > & options)
inlineexplicit

Definition at line 21 of file sortedLoopArray.h.

◆ SortedLoopArray() [2/2]

template<typename T>
visutwin::canvas::SortedLoopArray< T >::SortedLoopArray ( std::function< float(const T &)> keyExtractor)
inlineexplicit

Definition at line 24 of file sortedLoopArray.h.

Member Function Documentation

◆ append()

template<typename T>
void visutwin::canvas::SortedLoopArray< T >::append ( const T & item)
inline

Definition at line 43 of file sortedLoopArray.h.

References items, and length.

◆ insert()

template<typename T>
void visutwin::canvas::SortedLoopArray< T >::insert ( const T & item)
inline

Definition at line 33 of file sortedLoopArray.h.

References items, length, and loopIndex.

◆ remove()

template<typename T>
void visutwin::canvas::SortedLoopArray< T >::remove ( const T & item)
inline

Definition at line 49 of file sortedLoopArray.h.

References items, length, and loopIndex.

◆ sort()

template<typename T>
void visutwin::canvas::SortedLoopArray< T >::sort ( )
inline

Definition at line 64 of file sortedLoopArray.h.

References items, length, and loopIndex.

Member Data Documentation

◆ items

template<typename T>
std::vector<T> visutwin::canvas::SortedLoopArray< T >::items

Definition at line 29 of file sortedLoopArray.h.

Referenced by append(), insert(), remove(), and sort().

◆ length

template<typename T>
size_t visutwin::canvas::SortedLoopArray< T >::length = 0

Definition at line 30 of file sortedLoopArray.h.

Referenced by append(), insert(), remove(), and sort().

◆ loopIndex

template<typename T>
int visutwin::canvas::SortedLoopArray< T >::loopIndex = -1

Definition at line 31 of file sortedLoopArray.h.

Referenced by insert(), remove(), and sort().


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