|
JUCE-7.0.12-0-g4f43011b96 JUCE-7.0.12-0-g4f43011b96
JUCE — C++ application framework with suport for VST, VST3, LV2 audio plug-ins
« « « Anklang Documentation |
Implements some basic array storage allocation functions. More...
#include "juce_ArrayAllocationBase.h"
Public Member Functions | |
| ArrayAllocationBase ()=default | |
| Creates an empty array. | |
| ~ArrayAllocationBase ()=default | |
| Destructor. | |
| ArrayAllocationBase (ArrayAllocationBase &&other) noexcept | |
| ArrayAllocationBase & | operator= (ArrayAllocationBase &&other) noexcept |
| void | setAllocatedSize (int numElements) |
| Changes the amount of storage allocated. | |
| void | ensureAllocatedSize (int minNumElements) |
| Increases the amount of storage allocated if it is less than a given amount. | |
| void | shrinkToNoMoreThan (int maxNumElements) |
| Minimises the amount of storage allocated so that it's no more than the given number of elements. | |
| void | swapWith (ArrayAllocationBase &other) noexcept |
| Swap the contents of two objects. | |
Public Attributes | |
| HeapBlock< ElementType > | elements |
| int | numAllocated |
Implements some basic array storage allocation functions.
This class isn't really for public use - it used to be part of the container classes but has since been superseded by ArrayBase. Eventually it will be removed from the API.
@tags{Core}
Definition at line 37 of file juce_ArrayAllocationBase.h.
|
noexcept |
Definition at line 47 of file juce_ArrayAllocationBase.h.
| void juce::ArrayAllocationBase< ElementType, TypeOfCriticalSectionToUse >::ensureAllocatedSize | ( | int | minNumElements | ) |
Increases the amount of storage allocated if it is less than a given amount.
This will retain any data currently held in the array, but will add extra space at the end to make sure there it's at least as big as the size passed in. If it's already bigger, no action is taken.
| minNumElements | the minimum number of elements that are needed |
Definition at line 89 of file juce_ArrayAllocationBase.h.
|
noexcept |
Definition at line 53 of file juce_ArrayAllocationBase.h.
| void juce::ArrayAllocationBase< ElementType, TypeOfCriticalSectionToUse >::setAllocatedSize | ( | int | numElements | ) |
Changes the amount of storage allocated.
This will retain any data currently held in the array, and either add or remove extra space at the end.
| numElements | the number of elements that are needed |
Definition at line 68 of file juce_ArrayAllocationBase.h.
| void juce::ArrayAllocationBase< ElementType, TypeOfCriticalSectionToUse >::shrinkToNoMoreThan | ( | int | maxNumElements | ) |
Minimises the amount of storage allocated so that it's no more than the given number of elements.
Definition at line 100 of file juce_ArrayAllocationBase.h.
|
noexcept |
Swap the contents of two objects.
Definition at line 107 of file juce_ArrayAllocationBase.h.
| HeapBlock<ElementType> juce::ArrayAllocationBase< ElementType, TypeOfCriticalSectionToUse >::elements |
Definition at line 114 of file juce_ArrayAllocationBase.h.
| int juce::ArrayAllocationBase< ElementType, TypeOfCriticalSectionToUse >::numAllocated |
Definition at line 115 of file juce_ArrayAllocationBase.h.