]> Creatis software - bbtk.git/blobdiff - kernel/src/bbtkInterpreter.h
*** empty log message ***
[bbtk.git] / kernel / src / bbtkInterpreter.h
index 42db24dc637bda891c28aa9d8518f2b5f8f17104..483068bf8935c230eb008e9b08a5c6ef09941029 100644 (file)
@@ -3,8 +3,8 @@
   Program:   bbtk
   Module:    $RCSfile: bbtkInterpreter.h,v $ $
   Language:  C++
-  Date:      $Date: 2008/04/22 08:29:09 $
-  Version:   $Revision: 1.27 $
+  Date:      $Date: 2008/04/22 09:40:11 $
+  Version:   $Revision: 1.28 $
 
   Copyright (c) CREATIS (Centre de Recherche et d'Applications en Traitement de
   l'Image). All rights reserved. See Doc/License.txt or
@@ -28,6 +28,7 @@
 #define __bbtkInterpreter_h__
 
 #include "bbtkVirtualExec.h"
+#include "bbtkExecuter.h"
 
 #include <fstream>
 #include <deque>
@@ -116,17 +117,18 @@ namespace bbtk
     /// Sets the inputs of the workspace :
     /// the map is passed as is to the Executer
     void SetInputs(const std::map<std::string,std::string>& m)
-    { mExecuter->SetInputs(m); }
+    { mVirtualExecuter->SetInputs(m); }
 
     /// Puts the executer in "no exec" mode,
     /// which creates but does not execute pipelines.
-    void SetNoExecMode(bool b) { mExecuter->SetNoExecMode(b); }
+    void SetNoExecMode(bool b) { mVirtualExecuter->SetNoExecMode(b); }
 
     ///
     //typedef Executer::DialogModeType DialogModeType;
     typedef VirtualExec::DialogModeType DialogModeType;
 
-    void SetDialogMode(DialogModeType t) { mExecuter->SetDialogMode(t); }
+    void SetDialogMode(DialogModeType t) 
+    { mVirtualExecuter->SetDialogMode(t); }
 
     /// Sets the bool that indicates wether we are in command line context
     void SetCommandLine(bool v = true) { mCommandLine = v; }
@@ -144,7 +146,7 @@ namespace bbtk
 #endif
 
     /// Gets the Executer 
-    VirtualExec::Pointer GetExecuter() const { return mExecuter; }
+    VirtualExec::Pointer GetExecuter() const { return mVirtualExecuter; }
 
 
   protected:
@@ -281,7 +283,8 @@ namespace bbtk
     // ATTRIBUTES
 
     /// The command executer used
-    bbtk::VirtualExec::Pointer mExecuter;
+    bbtk::VirtualExec::Pointer mVirtualExecuter;
+    bbtk::Executer::WeakPointer mRealExecuter;
 
     /// The user of  the interpreter (0 if none)
     bbtk::InterpreterUser* mUser;