Homepage
Demos
Overview
Downloads
Dev. Resources
Reference
Credits

DataEvent< T > Class Template Reference

#include <DataEvent.h>

Inheritance diagram for DataEvent< T >:

Inheritance graph
[legend]
List of all members.

Detailed Description

template<class T>
class DataEvent< T >

for passing around data (or pointers to data)

Definition at line 9 of file DataEvent.h.

Public Member Functions

void setData (const T &d)
 assigns d to the internal data
const T & getData () const
 returns data
T & getData ()
 returns data
Constructors
 DataEvent ()
 DataEvent (const T &d, EventGeneratorID_t gid, unsigned int sid, EventTypeID_t tid, unsigned int dur=0)
 DataEvent (const T &d, EventGeneratorID_t gid, unsigned int sid, EventTypeID_t tid, unsigned int dur, const std::string &n, float mag)
 DataEvent (const DataEvent &evt)
 copy constructor
const DataEventoperator= (const DataEvent &evt)
 assignment
virtual EventBaseclone () const
 allows a copy to be made of an event, supporting polymorphism

Protected Attributes

data
 the data being communicated


Constructor & Destructor Documentation

template<class T>
DataEvent< T >::DataEvent  )  [inline]
 

Definition at line 13 of file DataEvent.h.

template<class T>
DataEvent< T >::DataEvent const T &  d,
EventGeneratorID_t  gid,
unsigned int  sid,
EventTypeID_t  tid,
unsigned int  dur = 0
[inline]
 

Definition at line 14 of file DataEvent.h.

template<class T>
DataEvent< T >::DataEvent const T &  d,
EventGeneratorID_t  gid,
unsigned int  sid,
EventTypeID_t  tid,
unsigned int  dur,
const std::string &  n,
float  mag
[inline]
 

Definition at line 15 of file DataEvent.h.

template<class T>
DataEvent< T >::DataEvent const DataEvent< T > &  evt  )  [inline]
 

copy constructor

Definition at line 18 of file DataEvent.h.


Member Function Documentation

template<class T>
virtual EventBase* DataEvent< T >::clone  )  const [inline, virtual]
 

allows a copy to be made of an event, supporting polymorphism

Must be overridden by all subclasses to allow this to happen

I would like to switch this over to the cloneable interface once the compiler gets updated out of the 3.3 branch... see Cloneable::clone() for a discussion of the issue and implementation notes.

Reimplemented from EventBase.

Definition at line 23 of file DataEvent.h.

template<class T>
T& DataEvent< T >::getData  )  [inline]
 

returns data

Definition at line 28 of file DataEvent.h.

template<class T>
const T& DataEvent< T >::getData  )  const [inline]
 

returns data

Definition at line 27 of file DataEvent.h.

Referenced by MicrophoneServer::processEvent(), LookForSoundBehavior::processEvent(), and BufferedImageGenerator::processEvent().

template<class T>
const DataEvent& DataEvent< T >::operator= const DataEvent< T > &  evt  )  [inline]
 

assignment

Definition at line 21 of file DataEvent.h.

template<class T>
void DataEvent< T >::setData const T &  d  )  [inline]
 

assigns d to the internal data

Definition at line 26 of file DataEvent.h.


Member Data Documentation

template<class T>
T DataEvent< T >::data [protected]
 

the data being communicated

Definition at line 31 of file DataEvent.h.

Referenced by DataEvent< T >::getData(), DataEvent< T >::operator=(), and DataEvent< T >::setData().


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

Tekkotsu v2.4.1
Generated Tue Aug 16 16:34:59 2005 by Doxygen 1.4.4