Program: bbtk
Module: $RCSfile: bbtkInterpreter.h,v $ $
Language: C++
- Date: $Date: 2008/03/21 11:44:37 $
- Version: $Revision: 1.19 $
+ Date: $Date: 2008/03/21 14:59:39 $
+ Version: $Revision: 1.20 $
Copyright (c) CREATIS (Centre de Recherche et d'Applications en Traitement de
l'Image). All rights reserved. See Doc/License.txt or
};
+ ///
+ class BBTK_EXPORT InterpreterError : public Exception
+ {
+ public:
+ InterpreterError( const std::string& message,
+ bool in_script_file,
+ const std::string& script_file,
+ int script_line
+ );
+ InterpreterError( const Exception& excep,
+ bool in_script_file,
+ const std::string& script_file,
+ int script_line
+ );
+ ~InterpreterError() throw() {}
+
+ bool IsInScriptFile() const { return mInScriptFile; }
+ const std::string& GetScriptFile() const { return mScriptFile; }
+ int GetScriptLine() const { return mScriptLine; }
+ private:
+ bool mInScriptFile;
+ std::string mScriptFile;
+ int mScriptLine;
+ };
+
+
+ ///
class BBTK_EXPORT Interpreter
{
void LoadScript( std::string fullPathScriptName,
std::string includeScriptName);
+ ///
+ void CatchBbtkException( const bbtk::Exception& e );
+ void CatchStdException( const std::exception& e );
+ void CatchUnknownException();
+
private:
//==================================================================