8 #include "IMovableItemCallback.h"
9 #include "ISimGUICallback.h"
13 #include "IPhysicsMovableItem.h"
14 #include "IPhysicsBody.h"
16 #include "MovableItem.h"
68 {
Std_TraceMsg(0,
"Caught Error in desctructor of ActivatedItemMgr\r\n",
"", -1,
false,
true);}
89 {
Std_TraceMsg(0,
"Caught Error in desctructor of DataChart\r\n",
"", -1,
false,
true);}
105 THROW_ERROR(Al_Err_lActivatedItemNull, Al_Err_strActivatedItemNull);
117 oError.
m_strError +=
" Duplicate activate item Key: " + lpItem->
ID();
179 for(iIndex=0; iIndex<iCount; iIndex++)
183 if(lpItem->
ID() == strID)
188 THROW_TEXT_ERROR(Al_Err_lActivatedItemIDNotFound, Al_Err_strActivatedItemIDNotFound,
" ActivatedItemID: " + strID);
212 CStdMap<std::string, ActivatedItem *>::iterator oPos;
216 lpItem = oPos->second;
218 THROW_TEXT_ERROR(Al_Err_lActivatedItemIDNotFound, Al_Err_strActivatedItemIDNotFound,
" ActivatedItemID: " + strID);
241 for(
int iIndex=0; iIndex<iCount; iIndex++)
246 THROW_PARAM_ERROR(Al_Err_lActivatedItemIDNotFound, Al_Err_strActivatedItemIDNotFound,
"ID",
m_strID);
257 for(
int iChart=0; iChart<iCount; iChart++)
266 for(
int iChart=0; iChart<iCount; iChart++)
275 for(
int iIndex=0; iIndex<iCount; iIndex++)
283 for(
int iIndex=0; iIndex<iCount; iIndex++)
virtual void ReInitialize()
Re-initialize this object.
Base class file for all Animat simulation objects.
virtual void Activate()
Activates this item.
Declares the simulation recorder class.
bool LessThanActivatedItemCompare(ActivatedItem *lpItem1, ActivatedItem *lpItem2)
Compares the start times of two activated items to see which is sooner.
Root namespace for the base simulation library for AnimatLab.
virtual void ResetSimulation()
Resets the simulation back to time 0.
Declares the body part class.
std::string m_strError
The error message.
virtual bool Enabled()
Gets whether the item is enabled or not.
Information about the standard error.
virtual std::string ID()
Gets the unique GUID ID of this object.
virtual ~ActivatedItemMgr()
Destructor.
long m_lError
The error number.
virtual void Initialize()
Initializes this object.
Declares the key frame class.
CStdPtrMap< std::string, ActivatedItem > m_aryItemsMap
Base class for all activated items.
bool IsActivated()
Query if this object is activated.
Declares the joint class.
Declares the organism class.
std::string m_strID
The unique Id for this object.
std::string Std_Trim(std::string strVal)
Trims a string.
Declares the activated item class.
Declares a light manager object.
Declares the bounding box class.
virtual void Initialize()
Initializes this object.
virtual void StepSimulation()
Step the simulation for this object.
virtual void StepSimulation()
Step the simulation for this object.
virtual void Reset()
Resets this manager.
bool NeedToActivate()
Determines if this item needs to be activated.
ActivatedItemMgr()
Default constructor.
CStdArray< ActivatedItem * > m_aryItems
void Std_TraceMsg(const int iLevel, std::string strMessage, std::string strSourceFile, int iSourceLine, bool bLogToFile, bool bPrintHeader)
Traces a message to the debugger window.
virtual ActivatedItem * Find(std::string strID, int &iIndex, bool bThrowError)
Searches for an item with the specified ID and sets its index in the array.
virtual void Deactivate()
Deactivates this item.
Declares the data chart manager class.
Declares the rigid body class.
std::string Std_CheckString(std::string strVal)
Converts a string to upper case and trims it.
virtual void Remove(std::string strID, bool bThrowError=true)
Removes the item with the specified ID.
Declares the structure class.
Declares the odor type class.
virtual bool NeedToStep()
Tells if this item needs to call StepSimulation or not.
Declares the simulator class.
virtual int FindListPos(std::string strID, bool bThrowError=true)
Searches for the item with the specified ID and returns its position in the m_aryItems array...
std::string Std_ToUpper(std::string strVal)
Converts a string to upper case.
Declares the activated item manager class.
Declares the external stimuli manager class.
bool NeedToDeactivate()
Determines if this item needs to be deactivated.
Declares the receptive field class.
virtual void Add(ActivatedItem *lpItem)
Adds a new ActivatedItem to be managed.