OSCNamespaceItem Class Reference

Represents a single component of the OSC namespace and contains the items underneath it. More...

#include <OSCNamespaceItem.h>

Collaboration diagram for OSCNamespaceItem:

[legend]
List of all members.

Public Types

typedef std::map< std::string,
OSCNamespaceItem *, std::less<
std::string > > 
ItemMap
typedef void(* TraverseFunction )(void *cookie, std::vector< std::string > &address, OSCNamespaceItem *item)

Public Member Functions

void setCallable (OSCCallable *callback)
OSCCallablegetCallable ()
bool traverse (const std::string &pattern, TraverseFunction tf, void *cookie=NULL)
 Call function tf for each address matching const std::string &pattern.
bool add (std::string name, OSCCallable *callback=NULL)
 Add address and optional callback to the namespace.
bool list (int level)
 print namespace recursive function for debugging

Public Attributes

ItemMap * mySubItems
OSCCallablemyCallable

Protected Member Functions

bool search_internal (void *cookie, TraverseFunction tf, std::vector< std::string > &address, const std::string &name, size_t offset)

Detailed Description

Represents a single component of the OSC namespace and contains the items underneath it.

/ foo / bar / baz

(the delimiters are only stored implicitly)

Author:
Daniel Holth


Member Function Documentation

bool OSCNamespaceItem::traverse const std::string &  pattern,
TraverseFunction  tf,
void *  cookie = NULL
 

Call function tf for each address matching const std::string &pattern.

  • pattern address or pattern to look up
  • tf void (*)(void*, std::vector <std::string>&, OSCNamespaceItem*) called for each matching address in the namespace
  • cookie optional state for function tf


The documentation for this class was generated from the following files:
Generated on Thu Mar 2 23:51:36 2006 for libOSC++ by  doxygen 1.4.6