UserControls Class Reference

#include <UserControls.h>

Collaboration diagram for UserControls:
Collaboration graph
[legend]

List of all members.

Public Member Functions

 UserControls (UserAgent *_ugent, Graph *_graph)
 ctor
 ~UserControls ()
 dtor
void processKeyDown (QKeyEvent *_event)
 processKeyDown passed from the Environment class
void processKeyUp (QKeyEvent *_event)
 processKeyUp passed from the Environment class
void ResetPosition ()
 reset the position of the agent
int getIndex ()
 get the index of the agent
int getNextIndex ()
 get the next Index of the agent
void initializeArray ()
 method to initialize the motion control array

Private Attributes

UserAgentm_parent
 pointer to the parent User
int m_precision
 variable to hold the precision
int m_index
 variable to hold the index
int m_nextIndex
 variable to hold the nextIndex
uint8_t m_keysPressed
 the keys being pressed
Graphm_graph
 a pointer for the graph
UserMotion m_motionTable [32]
 motion control table for user
bool m_key
 bool to check if the key is pressed initially

Detailed Description

Definition at line 48 of file UserControls.h.


Constructor & Destructor Documentation

UserControls::UserControls ( UserAgent _ugent,
Graph _graph 
)

ctor

Parameters:
[in] the parent user agent
[in] the graph node
UserControls::~UserControls (  ) 

dtor


Member Function Documentation

int UserControls::getIndex (  )  [inline]

get the index of the agent

Definition at line 80 of file UserControls.h.

References m_index.

00080 {return m_index;}

int UserControls::getNextIndex (  )  [inline]

get the next Index of the agent

Definition at line 84 of file UserControls.h.

References m_nextIndex.

00084 {return m_nextIndex;}

void UserControls::initializeArray (  ) 

method to initialize the motion control array

void UserControls::processKeyDown ( QKeyEvent *  _event  ) 

processKeyDown passed from the Environment class

Parameters:
*_event a pointer to the QKeyEvent passed from main window class
void UserControls::processKeyUp ( QKeyEvent *  _event  ) 

processKeyUp passed from the Environment class

Parameters:
*_event a pointer to the QKeyEvent passed from main window class
void UserControls::ResetPosition (  ) 

reset the position of the agent


Member Data Documentation

a pointer for the graph

Definition at line 112 of file UserControls.h.

int UserControls::m_index [private]

variable to hold the index

Definition at line 102 of file UserControls.h.

bool UserControls::m_key [private]

bool to check if the key is pressed initially

Definition at line 120 of file UserControls.h.

uint8_t UserControls::m_keysPressed [private]

the keys being pressed

Definition at line 108 of file UserControls.h.

motion control table for user

Definition at line 116 of file UserControls.h.

variable to hold the nextIndex

Definition at line 106 of file UserControls.h.

pointer to the parent User

Definition at line 94 of file UserControls.h.

variable to hold the precision

Definition at line 98 of file UserControls.h.


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

Generated on 16 Aug 2013 for Multi-AgentSystem by  doxygen 1.6.1