JUCE  v6.1.6 (6.0.8-1114)
JUCE API
Looking for a senior C++ dev?
I'm looking for work. Hire me!
juce::OSCBundle Class Reference

An OSC bundle. More...

#include <juce_OSCBundle.h>

Collaboration diagram for juce::OSCBundle:

Classes

class  Element
 An OSC bundle element. More...
 

Public Member Functions

 OSCBundle ()
 Constructs an OSCBundle with no content and a default time tag ("immediately"). More...
 
 OSCBundle (OSCTimeTag timeTag)
 Constructs an OSCBundle with no content and a given time tag. More...
 
void addElement (const OSCBundle::Element &element)
 Adds an OSCBundleElement to the OSCBundle's content. More...
 
const OSCBundle::Elementbegin () const noexcept
 Returns a pointer to the first element of the OSCBundle. More...
 
OSCBundle::Elementbegin () noexcept
 Returns a pointer to the first element of the OSCBundle. More...
 
const OSCBundle::Elementend () const noexcept
 Returns a pointer past the last element of the OSCBundle. More...
 
OSCBundle::Elementend () noexcept
 Returns a pointer past the last element of the OSCBundle. More...
 
OSCTimeTag getTimeTag () const noexcept
 Returns the OSCBundle's OSC time tag. More...
 
bool isEmpty () const noexcept
 Returns true if the bundle contains no elements; false otherwise. More...
 
const OSCBundle::Elementoperator[] (const int i) const noexcept
 
OSCBundle::Elementoperator[] (const int i) noexcept
 Returns a reference to the OSCBundle element at index i in this bundle. More...
 
void setTimeTag (OSCTimeTag newTimeTag) noexcept
 Sets the OSCBundle's OSC time tag. More...
 
int size () const noexcept
 Returns the number of elements contained in the bundle. More...
 

Private Attributes

Array< OSCBundle::Elementelements
 
OSCTimeTag timeTag
 

Detailed Description

An OSC bundle.

An OSCBundle contains an OSCTimeTag and zero or more OSCBundle Elements. The elements of a bundle can be OSC messages or other OSC bundles (this means that OSC bundles can be nested).

This is an advanced OSC structure useful to bundle OSC messages together whose effects must occur simultaneously at some given time. For most use cases it is probably enough to send and receive plain OSC messages.

@tags{OSC}

Constructor & Destructor Documentation

◆ OSCBundle() [1/2]

juce::OSCBundle::OSCBundle ( )

Constructs an OSCBundle with no content and a default time tag ("immediately").

◆ OSCBundle() [2/2]

juce::OSCBundle::OSCBundle ( OSCTimeTag  timeTag)

Constructs an OSCBundle with no content and a given time tag.

Member Function Documentation

◆ addElement()

void juce::OSCBundle::addElement ( const OSCBundle::Element element)
inline

Adds an OSCBundleElement to the OSCBundle's content.

s

◆ begin() [1/2]

const OSCBundle::Element* juce::OSCBundle::begin ( ) const
inlinenoexcept

Returns a pointer to the first element of the OSCBundle.

◆ begin() [2/2]

OSCBundle::Element* juce::OSCBundle::begin ( )
inlinenoexcept

Returns a pointer to the first element of the OSCBundle.

◆ end() [1/2]

const OSCBundle::Element* juce::OSCBundle::end ( ) const
inlinenoexcept

Returns a pointer past the last element of the OSCBundle.

◆ end() [2/2]

OSCBundle::Element* juce::OSCBundle::end ( )
inlinenoexcept

Returns a pointer past the last element of the OSCBundle.

◆ getTimeTag()

OSCTimeTag juce::OSCBundle::getTimeTag ( ) const
inlinenoexcept

Returns the OSCBundle's OSC time tag.

◆ isEmpty()

bool juce::OSCBundle::isEmpty ( ) const
inlinenoexcept

Returns true if the bundle contains no elements; false otherwise.

◆ operator[]() [1/2]

const OSCBundle::Element& juce::OSCBundle::operator[] ( const int  i) const
inlinenoexcept

◆ operator[]() [2/2]

OSCBundle::Element& juce::OSCBundle::operator[] ( const int  i)
inlinenoexcept

Returns a reference to the OSCBundle element at index i in this bundle.

This method does not check the range and results in undefined behaviour in case i < 0 or i >= size().

◆ setTimeTag()

void juce::OSCBundle::setTimeTag ( OSCTimeTag  newTimeTag)
inlinenoexcept

Sets the OSCBundle's OSC time tag.

◆ size()

int juce::OSCBundle::size ( ) const
inlinenoexcept

Returns the number of elements contained in the bundle.

Member Data Documentation

◆ elements

Array<OSCBundle::Element> juce::OSCBundle::elements
private

◆ timeTag

OSCTimeTag juce::OSCBundle::timeTag
private

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