This is a handy base class for the state of a processor (such as parameter values) which is typically shared among several processors. More...
#include <juce_ProcessContext.h>
Public Types | |
using | Ptr = ReferenceCountedObjectPtr< ProcessorState > |
The ProcessorState structure is ref-counted, so this is a handy type that can be used as a pointer to one. More... | |
Public Member Functions | |
void | decReferenceCount () noexcept |
Decreases the object's reference count. More... | |
bool | decReferenceCountWithoutDeleting () noexcept |
Decreases the object's reference count. More... | |
int | getReferenceCount () const noexcept |
Returns the object's current reference count. More... | |
void | incReferenceCount () noexcept |
Increments the object's reference count. More... | |
Protected Member Functions | |
void | resetReferenceCount () noexcept |
Resets the reference count to zero without deleting the object. More... | |
Private Attributes | |
Atomic< int > | refCount { 0 } |
This is a handy base class for the state of a processor (such as parameter values) which is typically shared among several processors.
This is useful for multi-mono filters which share the same state among several mono processors.
@tags{DSP}
The ProcessorState structure is ref-counted, so this is a handy type that can be used as a pointer to one.
|
inlinenoexceptinherited |
Decreases the object's reference count.
If the count gets to zero, the object will be deleted.
References jassert.
|
inlinenoexceptinherited |
Decreases the object's reference count.
If the count gets to zero, the object will not be deleted, but this method will return true, allowing the caller to take care of deletion.
References jassert.
|
inlinenoexceptinherited |
Returns the object's current reference count.
|
inlinenoexceptinherited |
Increments the object's reference count.
This is done automatically by the smart pointer, but is public just in case it's needed for nefarious purposes.
Referenced by juce::ReferenceCountedObjectPtr< juce::ReferenceCountedObject >::operator=().
|
inlineprotectednoexceptinherited |
Resets the reference count to zero without deleting the object.
You should probably never need to use this!