cmil::ContextActor Class Reference

#include <ContextActor.h>

Inheritance diagram for cmil::ContextActor:

Inheritance graph
[legend]
Collaboration diagram for cmil::ContextActor:

Collaboration graph
[legend]
List of all members.

Public Member Functions

 ContextActor (System *const sys)
virtual ~ContextActor ()
std::string getName () const
virtual InputContextgetContext ()
void setContext (InputContext *const context)
void captureNormal (ModAction *action)
 This is essentially a copy of the InputContext interface.
Ev::SequencegetCaptured () const
bool addCombo (const Ev &event)
bool addNormal (const Ev &event)
bool removeNormal (const Ev &event)
virtual void update (const InputData &input)
virtual void update (const ModData &input)
void quit ()
 This is the interface by which the InputArbitrator interacts with the InputActor.
bool getQuit () const

Private Attributes

bool m_quit
InputContextm_context

Detailed Description

Definition at line 27 of file ContextActor.h.


Constructor & Destructor Documentation

ContextActor::ContextActor ( System *const   sys  ) 

Definition at line 31 of file ContextActor.cpp.

00031 : m_quit(false), m_context(new defaultContext(sys)) {}; 

virtual cmil::ContextActor::~ContextActor (  )  [inline, virtual]

Definition at line 31 of file ContextActor.h.

References Logger::log_debug(), and m_context.

00031                               {
00032         log_debug("calling dtor");
00033 
00034         if(m_context) {
00035           log_debug("deleting context");
00036           delete m_context;
00037         }
00038       };

Here is the call graph for this function:


Member Function Documentation

bool ContextActor::addCombo ( const Ev event  ) 

Definition at line 65 of file ContextActor.cpp.

References cmil::InputContext::addCombo(), and ContextActor::m_context.

00065                                              {
00066     return m_context->addCombo(event);
00067   };

Here is the call graph for this function:

bool ContextActor::addNormal ( const Ev event  ) 

Definition at line 69 of file ContextActor.cpp.

References cmil::InputContext::addNormal(), and ContextActor::m_context.

Referenced by Application::init().

00069                                               {
00070     return m_context->addNormal(event);
00071   };

Here is the call graph for this function:

Here is the caller graph for this function:

void ContextActor::captureNormal ( ModAction action  ) 

This is essentially a copy of the InputContext interface.

Definition at line 57 of file ContextActor.cpp.

References cmil::InputContext::captureNormal(), and ContextActor::m_context.

00057                                                       {
00058     m_context->captureNormal(action);
00059   };

Here is the call graph for this function:

Ev::Sequence * ContextActor::getCaptured (  )  const

Definition at line 61 of file ContextActor.cpp.

References cmil::InputContext::getCaptured(), and ContextActor::m_context.

00061                                                 {
00062     return m_context->getCaptured();
00063   };

Here is the call graph for this function:

InputContext * ContextActor::getContext (  )  [virtual]

Definition at line 37 of file ContextActor.cpp.

References ContextActor::m_context.

00037                                          {
00038     return m_context;
00039   };

std::string ContextActor::getName (  )  const [virtual]

Reimplemented from cmil::InputActor.

Definition at line 33 of file ContextActor.cpp.

00033                                         {
00034     return "ContextActor";
00035   };

bool ContextActor::getQuit (  )  const

Definition at line 52 of file ContextActor.cpp.

Referenced by Application::run().

00052                                    {
00053     return m_quit;
00054   };

Here is the caller graph for this function:

void ContextActor::quit (  )  [virtual]

This is the interface by which the InputArbitrator interacts with the InputActor.

Implements cmil::InputActor.

Definition at line 48 of file ContextActor.cpp.

00048                           {
00049     m_quit = true;
00050   };

bool ContextActor::removeNormal ( const Ev event  ) 

Definition at line 73 of file ContextActor.cpp.

References ContextActor::m_context, and cmil::InputContext::removeNormal().

00073                                                  {
00074     return m_context->removeNormal(event);
00075   };

Here is the call graph for this function:

void ContextActor::setContext ( InputContext *const   context  ) 

Definition at line 41 of file ContextActor.cpp.

References ContextActor::m_context.

00041                                                            {
00042     if(context)
00043       m_context = context; 
00044     else 
00045       log_error("setContext() attemptted to assign null context");
00046   };

void ContextActor::update ( const ModData input  )  [virtual]

Implements cmil::InputActor.

Definition at line 81 of file ContextActor.cpp.

References ContextActor::m_context, and cmil::InputContext::update().

00081                                                 {
00082     m_context->update(input);
00083   };

Here is the call graph for this function:

void ContextActor::update ( const InputData input  )  [virtual]

Implements cmil::InputActor.

Definition at line 77 of file ContextActor.cpp.

References ContextActor::m_context, and cmil::InputContext::update().

00077                                                   { 
00078     m_context->update(input);
00079   };

Here is the call graph for this function:


Member Data Documentation

InputContext* cmil::ContextActor::m_context [private]

Definition at line 62 of file ContextActor.h.

Referenced by ~ContextActor().

bool cmil::ContextActor::m_quit [private]

Definition at line 61 of file ContextActor.h.


The documentation for this class was generated from the following files:
(c) 2006-2007 John P. Feltz
Generated on Wed Jul 25 16:08:02 2007 for Common Media Input Layer by doxygen 1.4.7

SourceForge.net Logo