A class that represents a dynamically-sized sequence of objects stored contiguously in memory.
More...
|
| | ShortArray () |
| | Create an empty array. This constructor does not allocate any memory. More...
|
| |
| | ShortArray (SizeType arraySize) |
| | Create an array of the specified size with default-constructed elements. More...
|
| |
| | ShortArray (SizeType arraySize, const T &prototype) |
| | Create an array of the specified size with elements created from the specified prototype. More...
|
| |
| | ShortArray (T *newArray, SizeType arraySize) |
| | Create an array which uses the specified pointer to a block of memory. More...
|
| |
| | ShortArray (const T *newArray, SizeType arraySize) |
| | Create an array with elements from the specified pointer, copying the data. More...
|
| |
| | ShortArray (const ShortArray &other) |
| | Create a deep copy of the specified array object. More...
|
| |
| template<Size localCapacity2> |
| | ShortArray (const ShortArray< T, localCapacity2, SizeType > &other) |
| | Create a deep copy of the specified array object. More...
|
| |
| template<Size localCapacity2> |
| | ShortArray (const ShortArray< T, localCapacity2, SizeType > &other, SizeType number) |
| | Create a deep copy of the specified array object, using only the specified number of elements. More...
|
| |
| | ~ShortArray () |
| | Destroy an array object and deallocate its internal array. More...
|
| |
| ShortArray & | operator= (const ShortArray &other) |
| | Copy the contents from another array into this array, replacing the current contents. More...
|
| |
| template<Size localCapacity2> |
| ShortArray< T, localCapacity, SizeType > & | operator= (const ShortArray< T, localCapacity2, SizeType > &other) |
| | Copy the contents from another array into this array, replacing the current contents. More...
|
| |
| T * | getPointer () |
| | Convert this array to a pointer and return the result. More...
|
| |
| const T * | getPointer () const |
| | Convert this array to a pointer and return the result, const version. More...
|
| |
| | operator T * () |
| | Convert this array to a pointer. More...
|
| |
| | operator const T * () const |
| | Convert this array to a pointer, const version. More...
|
| |
| template<Size localCapacity2> |
| Bool | operator== (const ShortArray< T, localCapacity2, SizeType > &array) const |
| | Compare this array to another array for equality. More...
|
| |
| template<Size localCapacity2> |
| Bool | operator!= (const ShortArray< T, localCapacity2, SizeType > &array) const |
| | Compare this array to another array for inequality. More...
|
| |
| template<Size localCapacity2> |
| ShortArray< T, localCapacity, SizeType > | operator+ (const ShortArray< T, localCapacity2, SizeType > &other) const |
| | Concatenate the contents of this array with another array and return the resulting new array. More...
|
| |
| SizeType | getSize () const |
| | Get the size of this array. More...
|
| |
| void | setSize (SizeType newSize) |
| | Resize this array, copying as many elements from the old array to the new array as possible. More...
|
| |
| void | setSize (SizeType newSize, const T &prototype) |
| | Resize this array, copying as many elements from the old array to the new array as possible. More...
|
| |
| void | setAll (const T &prototype) |
| | Set all of the values in this array to the specified value. More...
|
| |
template<typename T, Size localCapacity = Size(4), typename SizeType = Size>
class om::util::ShortArray< T, localCapacity, SizeType >
A class that represents a dynamically-sized sequence of objects stored contiguously in memory.
This class functions identically to the Array class, except that it has local storage for a small number of objects that are stored as part of the array object, eliminating an array allocation if the number of objects is small.