A dynamic buffer as typed array. Has range check on any index.
More...
#include <TDynamicArray.h>
|
| | TDynamicArray ()=default |
| | Default constructor.
|
| |
| | TDynamicArray (const TDynamicBuffer< Alloc > &buf) |
| | Dynamic array constructor.
|
| |
| | TDynamicArray (size_t sz) |
| | Initialization constructor.
|
| |
| size_t | count () const |
| | Returns the size of the array.
|
| |
| size_t | size () const |
| | Returns the size of the array.
|
| |
| void * | data () |
| | Returns a typed pointer to the start of the array.
|
| |
| T & | operator[] (size_t i) |
| | Returns reference of the specified index.
|
| |
| | operator T* () |
| | Returns a typed pointer to the start of the array.
|
| |
| | operator T* () const |
| | Returns a typed pointer to the start of the array.
|
| |
| | operator const void * () const |
| | Returns a typed pointer to the start of the array.
|
| |
| | operator void * () |
| | Returns a typed pointer to the start of the array.
|
| |
| void | resize (size_t sz, bool shrink=false) |
| | Resizes the array but does leave the data in tact.
|
| |
| void | grow (size_t sz) |
| | Grows the array to the specified size but keeps the current data intact.
|
| |
| void | zero () |
| | Zeroes all data.
|
| |
| | operator TDynamicBuffer< Alloc > () |
| | Cast operator the TDynamic buffer.
|
| |
| TDynamicBuffer< Alloc > & | getBuffer () |
| | Gets access to the underlying buffer.
|
| |
template<typename T, typename Alloc = Allocator>
class sf::TDynamicArray< T, Alloc >
A dynamic buffer as typed array. Has range check on any index.
- See also
- sf::TDynamicBuffer
◆ TDynamicArray() [1/3]
template<typename T , typename Alloc = Allocator>
◆ TDynamicArray() [2/3]
template<typename T , typename Alloc = Allocator>
Dynamic array constructor.
◆ TDynamicArray() [3/3]
template<typename T , typename Alloc = Allocator>
Initialization constructor.
◆ count()
template<typename T , typename Alloc = Allocator>
Returns the size of the array.
◆ data()
template<typename T , typename Alloc = Allocator>
Returns a typed pointer to the start of the array.
◆ getBuffer()
template<typename T , typename Alloc = Allocator>
Gets access to the underlying buffer.
◆ grow()
template<typename T , typename Alloc = Allocator>
Grows the array to the specified size but keeps the current data intact.
◆ operator const void *()
template<typename T , typename Alloc = Allocator>
Returns a typed pointer to the start of the array.
◆ operator T*() [1/2]
template<typename T , typename Alloc = Allocator>
Returns a typed pointer to the start of the array.
◆ operator T*() [2/2]
template<typename T , typename Alloc = Allocator>
Returns a typed pointer to the start of the array.
◆ operator TDynamicBuffer< Alloc >()
template<typename T , typename Alloc = Allocator>
Cast operator the TDynamic buffer.
◆ operator void *()
template<typename T , typename Alloc = Allocator>
Returns a typed pointer to the start of the array.
◆ operator[]()
template<typename T , typename Alloc = Allocator>
Returns reference of the specified index.
◆ resize()
template<typename T , typename Alloc = Allocator>
◆ size()
template<typename T , typename Alloc = Allocator>
Returns the size of the array.
◆ zero()
template<typename T , typename Alloc = Allocator>
◆ _buffer
template<typename T , typename Alloc = Allocator>
Holds the underlying storage buffer.
The documentation for this class was generated from the following file: