]> git.tdb.fi Git - builder.git/blobdiff - source/externalaction.h
Reorder class members
[builder.git] / source / externalaction.h
index 52eed37e5da12857725d19b128b2f2869dc5cb27..6df268fd4c25e325fff5976da97ba9aab1f372c4 100644 (file)
@@ -1,20 +1,36 @@
+/* $Id$
+
+This file is part of builder
+Copyright © 2006-2009  Mikko Rasa, Mikkosoft Productions
+Distributed under the LGPL
+*/
+
 #ifndef EXTERNALACTION_H_
 #define EXTERNALACTION_H_
 
 #include <list>
 #include <string>
 #include "action.h"
+#include "misc.h"
 
+/**
+Base class for Actions that want to execute an external program.
+*/
 class ExternalAction: public Action
 {
-public:
-       int check();
 protected:
-       std::list<std::string> argv;
+       StringList argv;
+       Msp::FS::Path work_dir;
        int pid;
+       int exit_code;
        
-       ExternalAction(Builder &b): Action(b) { }
+       ExternalAction(Builder &b): Action(b), pid(0), exit_code(0) { }
+
+       /** Starts the external program.  Fill in argv before calling this. */
        void launch();
+
+public:
+       virtual int check();
 };
 
 #endif