DRDE/ACTK1_0/se/LPE/LPCmdExtender.hpp

31 lines
671 B
C++

#ifndef _LPE_COMMAND_EXTENSION_HPP_
#define _LPE_COMMAND_EXTENSION_HPP_
#include "se/Command.hpp"
#include "se/CommandExtension.hpp"
#include "LPLaunch.hpp"
class LPCmdExtender : public CommandExtension
{
public:
virtual void addToCommand(const Command &command) const;
void setCreateData(LPLaunch* createData);
void createXMLElement(XMLWriter* xmlWriter, DOMElement* addElement);
LPCmdExtender(Command x) : t(x.getCommandType()) {}
private:
const CommandType *t;
std::auto_ptr<LPLaunch> createData;
};
inline void LPCmdExtender::setCreateData(LPLaunch* createData)
{
this->createData.reset(createData);
}
#endif /* _LPE_COMMAND_EXTENSION_HPP_ */