/** * @file command_list.hpp * @author Julian Iseringhausen * @date Tue Apr 5 20:28:02 2011 * * @brief This class holds a list of commands. These commands * can be executed by calling ExecuteList. * */ #ifndef COMMAND_LIST_HPP_ #define COMMAND_LIST_HPP_ #include #include #include #include "base/defs.hpp" #include "base/object.hpp" namespace VMG { class Command; class CommandList : public Object { public: typedef std::list< std::pair > >::iterator iterator; Request ExecuteList(); ///< Execute all commands in this list. void AddCommand(std::string command, std::string arguments = ""); ///< Add a command to the back of the list. void DeleteCommand(const CommandList::iterator& iter); ///< Remove a command from the list. void Print(); ///< Print all commands in list. void Clear(); ///< Remove all commands from list. private: std::list< std::pair > > commands; }; } #endif /* COMMAND_LIST_HPP_ */