JUCE v8.0.9
JUCE API
 
Loading...
Searching...
No Matches
juce::midi_ci::DeviceFeatures Class Reference

Flags indicating the features that are supported by a given CI device. More...

#include <juce_CIDeviceFeatures.h>

Collaboration diagram for juce::midi_ci::DeviceFeatures:

Public Member Functions

 DeviceFeatures ()=default
 Constructs a DeviceFeatures object with no flags enabled.
 
 DeviceFeatures (std::byte f)
 Constructs a DeviceFeatures object, taking flag values from the "Capability Inquiry Category Supported" byte in a CI Discovery message.
 
std::byte getSupportedCapabilities () const
 Returns the feature flags formatted into a bitfield suitable for use as the "Capability Inquiry Category Supported" byte in a CI Discovery message.
 
bool isProcessInquirySupported () const
 
bool isProfileConfigurationSupported () const
 
bool isPropertyExchangeSupported () const
 
bool operator!= (const DeviceFeatures &other) const
 Returns true if any flags in this and other differ.
 
bool operator== (const DeviceFeatures &other) const
 Returns true if this and other both have the same flags set.
 
DeviceFeatures withProcessInquirySupported (bool x=true) const
 Returns a new DeviceFeatures instance with process inquiry marked as supported.
 
DeviceFeatures withProfileConfigurationSupported (bool x=true) const
 Returns a new DeviceFeatures instance with profile configuration marked as supported.
 
DeviceFeatures withPropertyExchangeSupported (bool x=true) const
 Returns a new DeviceFeatures instance with property exchange marked as supported.
 

Private Types

enum  Flags {
  profileConfiguration = 1 << 2 ,
  propertyExchange = 1 << 3 ,
  processInquiry = 1 << 4
}
 

Private Member Functions

bool getFlag (Flags f) const
 
DeviceFeatures withFlag (Flags f, bool value) const
 

Private Attributes

uint8_t flags = 0
 

Detailed Description

Flags indicating the features that are supported by a given CI device.

@tags{Audio}

Member Enumeration Documentation

◆ Flags

Enumerator
profileConfiguration 
propertyExchange 
processInquiry 

Constructor & Destructor Documentation

◆ DeviceFeatures() [1/2]

juce::midi_ci::DeviceFeatures::DeviceFeatures ( )
default

Constructs a DeviceFeatures object with no flags enabled.

◆ DeviceFeatures() [2/2]

juce::midi_ci::DeviceFeatures::DeviceFeatures ( std::byte  f)
inlineexplicit

Constructs a DeviceFeatures object, taking flag values from the "Capability Inquiry Category Supported" byte in a CI Discovery message.

Member Function Documentation

◆ getFlag()

bool juce::midi_ci::DeviceFeatures::getFlag ( Flags  f) const
inlineprivate

◆ getSupportedCapabilities()

std::byte juce::midi_ci::DeviceFeatures::getSupportedCapabilities ( ) const
inline

Returns the feature flags formatted into a bitfield suitable for use as the "Capability Inquiry Category Supported" byte in a CI Discovery message.

References flags.

◆ isProcessInquirySupported()

bool juce::midi_ci::DeviceFeatures::isProcessInquirySupported ( ) const
inline

◆ isProfileConfigurationSupported()

bool juce::midi_ci::DeviceFeatures::isProfileConfigurationSupported ( ) const
inline

◆ isPropertyExchangeSupported()

bool juce::midi_ci::DeviceFeatures::isPropertyExchangeSupported ( ) const
inline

◆ operator!=()

bool juce::midi_ci::DeviceFeatures::operator!= ( const DeviceFeatures other) const
inline

Returns true if any flags in this and other differ.

References operator==().

◆ operator==()

bool juce::midi_ci::DeviceFeatures::operator== ( const DeviceFeatures other) const
inline

Returns true if this and other both have the same flags set.

References flags.

Referenced by operator!=().

◆ withFlag()

DeviceFeatures juce::midi_ci::DeviceFeatures::withFlag ( Flags  f,
bool  value 
) const
inlineprivate

◆ withProcessInquirySupported()

DeviceFeatures juce::midi_ci::DeviceFeatures::withProcessInquirySupported ( bool  x = true) const
inline

Returns a new DeviceFeatures instance with process inquiry marked as supported.

References processInquiry, and withFlag().

◆ withProfileConfigurationSupported()

DeviceFeatures juce::midi_ci::DeviceFeatures::withProfileConfigurationSupported ( bool  x = true) const
inline

Returns a new DeviceFeatures instance with profile configuration marked as supported.

References profileConfiguration, and withFlag().

◆ withPropertyExchangeSupported()

DeviceFeatures juce::midi_ci::DeviceFeatures::withPropertyExchangeSupported ( bool  x = true) const
inline

Returns a new DeviceFeatures instance with property exchange marked as supported.

References propertyExchange, and withFlag().

Member Data Documentation

◆ flags

uint8_t juce::midi_ci::DeviceFeatures::flags = 0
private

The documentation for this class was generated from the following file: