DSPatch  v.5.01
Classes | Public Member Functions | List of all members
DSPatch::Signal Class Referencefinal

Value container used to carry data between components. More...

#include <Signal.h>

Public Member Functions

bool HasValue () const
template<class ValueType >
ValueType * GetValue ()
template<class ValueType >
void SetValue (ValueType const &newValue)
bool CopySignal (Signal::SPtr const &fromSignal)
bool MoveSignal (Signal::SPtr const &fromSignal)
void ClearValue ()
std::type_info const & GetType () const

Detailed Description

Value container used to carry data between components.

Components process and transfer data between each other in the form of "signals" via interconnected wires. The Signal class holds a single value that can be dynamically typed at runtime. Furthermore, a Signal has the ability to change it's data type at any point during program execution. This is designed such that a signal bus can hold any number of different typed variables, as well as to allow for a variable to dynamically change it's type when needed - this can be useful for inputs that accept a number of different data types (E.g. Varying sample size in an audio buffer: array of byte / int / float).

Definition at line 44 of file Signal.h.

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