Switchboard SDK
Loading...
Searching...
No Matches
switchboard::AudioBusFormatList Struct Referenceabstract

Holds a list of AudioBusList instances. More...

#include <AudioBusFormatList.hpp>

Inheritance diagram for switchboard::AudioBusFormatList:
switchboard::AudioBusFormatArray< N > switchboard::AudioBusFormatVector

Public Member Functions

 AudioBusFormatList ()=default
 Default constructor for AudioBusFormatList.
 
virtual ~AudioBusFormatList ()=default
 Default destructor for AudioBusFormatList.
 
virtual uint getNumberOfBuses () const =0
 Returns the number of audio bus formats.
 
virtual AudioBusFormatgetBusFormat (const uint busIndex) const =0
 Returns the audio bus format for the specified index.
 
virtual AudioBusFormatListoperator= (const AudioBusFormatList &other)=0
 Makes an audio bus format list equal to another audio bus format list.
 
void reset ()
 Resets all audio bus formats stored in the instance.
 
bool isSet () const
 Checks whether all audio bus formats are set.
 
bool isPartlySet () const
 Checks whether any of the audio bus formats are set.
 
bool operator== (const AudioBusFormatList &other)
 Compares two audio bus format lists.
 
bool operator!= (const AudioBusFormatList &other)
 Compares two audio bus format lists.
 
std::string toString () const
 Returns a string representing the object.
 
 AudioBusFormatList (const AudioBusFormatList &)=delete
 

Static Public Member Functions

static bool matchBusFormats (AudioBusFormatList &busFormats)
 Matches all bus formats in an AudioBusFormatList instance.
 
static bool matchBusFormats (AudioBusFormatList &busFormatList1, AudioBusFormatList &busFormatList2)
 Matches all bus formats in two AudioBusFormatList instances.
 

Detailed Description

Holds a list of AudioBusList instances.

AudioBusFormatList abstract superclass.

Represents formats of AudioBusList instances without the need for the audio data.

See also
AudioBusFormatArray
AudioBusFormatVector

Member Function Documentation

◆ getBusFormat()

virtual AudioBusFormat & switchboard::AudioBusFormatList::getBusFormat ( const uint busIndex) const
pure virtual

Returns the audio bus format for the specified index.

Parameters
busIndexThe index of the audio bus.
Returns
The AudioBusFormat for the bus index.

Implemented in switchboard::AudioBusFormatArray< N >, and switchboard::AudioBusFormatVector.

◆ getNumberOfBuses()

virtual uint switchboard::AudioBusFormatList::getNumberOfBuses ( ) const
pure virtual

Returns the number of audio bus formats.

Returns
The number of audio buses.

Implemented in switchboard::AudioBusFormatArray< N >, and switchboard::AudioBusFormatVector.

◆ isPartlySet()

bool switchboard::AudioBusFormatList::isPartlySet ( ) const

Checks whether any of the audio bus formats are set.

Returns
True if any of the audio bus formats are defined, false otherwise.

◆ isSet()

bool switchboard::AudioBusFormatList::isSet ( ) const

Checks whether all audio bus formats are set.

Returns
True if all audio bus formats are defined, false otherwise.

◆ matchBusFormats() [1/2]

bool switchboard::AudioBusFormatList::matchBusFormats ( AudioBusFormatList & busFormatList1,
AudioBusFormatList & busFormatList2 )
static

Matches all bus formats in two AudioBusFormatList instances.

Finds the first defined bus format and requires the same bus format for all of the other buses. If none of the bus formats are defined, it returns with false.

Parameters
busFormatList1The first bus format list in which the bus formats will be matched.
busFormatList2The second bus format list in which the bus formats will be matched.
Returns
True if the bus formats could be matched successfully, false otherwise.

◆ matchBusFormats() [2/2]

bool switchboard::AudioBusFormatList::matchBusFormats ( AudioBusFormatList & busFormats)
static

Matches all bus formats in an AudioBusFormatList instance.

Finds the first defined bus format and requires the same bus format for all of the other buses. If none of the bus formats are defined, it returns with false.

Parameters
busFormatsThe bus format list in which the bus formats will be matched.
Returns
True if the bus formats could be matched successfully, false otherwise.

◆ operator!=()

bool switchboard::AudioBusFormatList::operator!= ( const AudioBusFormatList & other)

Compares two audio bus format lists.

Parameters
otherThe other AudioBusFormatList instance.
Returns
True if the stored audio bus formats are different, false otherwise.

◆ operator=()

virtual AudioBusFormatList & switchboard::AudioBusFormatList::operator= ( const AudioBusFormatList & other)
pure virtual

Makes an audio bus format list equal to another audio bus format list.

Parameters
otherThe other audio bus format list.

Implemented in switchboard::AudioBusFormatArray< N >, and switchboard::AudioBusFormatVector.

◆ operator==()

bool switchboard::AudioBusFormatList::operator== ( const AudioBusFormatList & other)

Compares two audio bus format lists.

Parameters
otherThe other AudioBusFormatList instance.
Returns
True if all audio bus formats match, false otherwise.

◆ toString()

std::string switchboard::AudioBusFormatList::toString ( ) const

Returns a string representing the object.

Returns
A string representing the object.