Ardour  9.0-pre0-386-g96ef4d20f2
AudioGrapher::Throwing< L > Class Template Reference

#include <throwing.h>

Inheritance diagram for AudioGrapher::Throwing< L >:
[legend]

Protected Member Functions

 Throwing ()
 
bool throw_level (ThrowLevel level)
 

Detailed Description

template<ThrowLevel L = ThrowStrict>
class AudioGrapher::Throwing< L >

Class that allows optimizing out error checking during compile time. Usage: to take all advantage of this class you should wrap all throwing statemets like this:

if (throw_level (SomeThrowLevel) && other_optional_conditionals) {
throw Exception (...);
}
bool throw_level(ThrowLevel level)
Definition: throwing.h:47

The order of the conditionals in the if-clause is important. The checks specified in other_optional_conditionals are only optimized out if throw_level() is placed before it with a logical and (short-circuiting).

Definition at line 43 of file throwing.h.

Constructor & Destructor Documentation

◆ Throwing()

template<ThrowLevel L = ThrowStrict>
AudioGrapher::Throwing< L >::Throwing ( )
inlineprotected

Definition at line 46 of file throwing.h.

Member Function Documentation

◆ throw_level()

template<ThrowLevel L = ThrowStrict>
bool AudioGrapher::Throwing< L >::throw_level ( ThrowLevel  level)
inlineprotected

Definition at line 47 of file throwing.h.


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