Game Accessibility Library logo SourceForge.net Logo
Game Accessibility Suite: CATGUI/CATCommand.cpp Source File

CATCommand.cpp

Go to the documentation of this file.
00001 //---------------------------------------------------------------------------
00002 /// \file CATCommand.cpp
00003 /// \brief Generalized command construct for tracking commands
00004 /// \ingroup CATGUI
00005 /// 
00006 /// Copyright (c) 2003-2008 by Michael Ellison.
00007 /// See COPYING.txt for the \ref gaslicense License (MIT License).
00008 ///
00009 // $Author: mikeellison $
00010 // $Date: 2008-01-23 01:43:25 -0600 (Wed, 23 Jan 2008) $
00011 // $Revision:   $
00012 // $NoKeywords: $
00013 //---------------------------------------------------------------------------
00014 #include <memory.h>
00015 
00016 #include "CATCommand.h"
00017 
00018 CATCommand::CATCommand()
00019 {
00020     fVal              = 1.0f;
00021     fCmdString        = "";
00022     fCmdType          = "";
00023     fTarget           = "";
00024     fStrParam         = "";
00025 }
00026 
00027 CATCommand::CATCommand(  const CATString& cmdString, 
00028                        CATFloat32         cmdVal,
00029                        const CATString& cmdStrParam,
00030                        const CATString& cmdTarget,
00031                        const CATString& cmdType)
00032 {
00033     fCmdType          = cmdType;
00034     fCmdString        = cmdString;
00035     fVal              = cmdVal;
00036     fStrParam         = cmdStrParam;
00037     fTarget           = cmdTarget;
00038 }
00039 
00040 CATCommand::~CATCommand()
00041 {
00042 }
00043 
00044 CATCommand& CATCommand::operator=(const CATCommand& cmd)
00045 {
00046     fCmdType    = cmd.fCmdType;
00047     fTarget     = cmd.fTarget;
00048     fCmdString  = cmd.fCmdString;
00049     fVal        = cmd.fVal;
00050     fStrParam   = cmd.fStrParam;
00051     return *this;
00052 }
00053 
00054 CATFloat32  CATCommand::GetValue()
00055 {
00056     return fVal;
00057 }
00058 
00059 CATString CATCommand::GetCmdString()
00060 {
00061     return fCmdString;
00062 }
00063 
00064 CATString CATCommand::GetStringParam()
00065 {
00066     return fStrParam;
00067 }
00068 
00069 
00070 CATString CATCommand::GetTarget()
00071 {
00072     return fTarget;
00073 }
00074 
00075 CATString CATCommand::GetType()
00076 {
00077     return fCmdType;
00078 }

Generated on Mon Feb 11 04:09:51 2008 for Game Accessibility Suite by doxygen 1.5.4