wmi

git clone git://oldgit.suckless.org/wmi/
Log | Files | Refs | LICENSE

launcher.h (709B)


      1 // Copyright (c) 2003 - 2009 Anselm R Garbe <anselm@garbe.us>
      2 // See LICENSE for license details.
      3 
      4 #ifndef __LAUNCHER_H
      5 #define __LAUNCHER_H
      6 
      7 #include <string>
      8 
      9 #include "wmi.h"
     10 
     11 #include "singleton.h"
     12 
     13 // forward declaration
     14 class Action;
     15 class Launcher;
     16 
     17 /**
     18  * Launches external processes and is capable to process chain
     19  * invocations.
     20  *
     21  * Determines recursion in chain invocation.
     22  */
     23 class Launcher : public Singleton<Launcher>
     24 {
     25 
     26 public:
     27 
     28     /** Constructs a new process manager instance.  */
     29     Launcher();
     30 
     31     ~Launcher();
     32 
     33     /** Execs the given command. */
     34     void exec(string command);
     35 
     36     /** Execs a chain. */
     37     void execSeq(Action *caller, string command);
     38 };
     39 
     40 #endif // __LAUNCHER_H