2 Copyright (c) 2006 Paolo Capriotti <p.capriotti@sns.it>
3 (c) 2006 Maurizio Monge <maurizio.monge@kdemail.net>
5 This program is free software; you can redistribute it and/or modify
6 it under the terms of the GNU General Public License as published by
7 the Free Software Foundation; either version 2 of the License, or
8 (at your option) any later version.
14 #include <boost/shared_ptr.hpp>
21 typedef boost::shared_ptr
<Agent
> AgentPtr
;
22 typedef std::vector
<AgentPtr
> AgentList
;
24 weak_set
<Agent
> m_agents
;
26 void addAgent(const AgentPtr
& agent
);
28 void clockUpdate(Agent
* source
, int, int);
29 void move(Agent
* source
, AbstractMove::Ptr
, AbstractPosition::Ptr
);
30 void back(Agent
* source
);
31 void forward(Agent
* source
);
32 void gotoFirst(Agent
* source
);
33 void gotoLast(Agent
* source
);
36 class AgentGroupDispatcher
{
40 AgentGroupDispatcher(AgentGroup
* group
, Agent
* agent
);
41 virtual ~AgentGroupDispatcher(){}
43 virtual void clockUpdate(int, int);
44 virtual bool move(AbstractMove::Ptr
, AbstractPosition::Ptr
);
46 virtual bool forward();
47 virtual bool gotoFirst();
48 virtual bool gotoLast();
51 #endif // AGENTGROUP_H