00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020 #ifndef NONGUI_H
00021 #define NONGUI_H
00022
00023 #include "src/config.h"
00024 #include "src/presentation/frontends/frontend.h"
00025 #include "src/domain/domainfacade.h"
00026
00032 class NonGUIFrontend : public Frontend
00033 {
00034 public:
00039 NonGUIFrontend(DomainFacade *facadePtr);
00040 virtual ~NonGUIFrontend();
00041
00048 int run(int argc, char **argv);
00049
00055 void showProgress(const char *infoText, unsigned int numOperations);
00056
00060 void hideProgress();
00061
00066 void updateProgress(int numOperationsDone);
00067
00072 void setProgressInfo(const char *infoText);
00073
00079 bool isOperationAborted();
00080
00086 void processEvents();
00087
00094 void reportError(const char *message, int id);
00095
00101 int askQuestion(const char *question);
00102
00103 private:
00104 DomainFacade *facadePtr;
00105
00106 int parseArguments(int argc, char **argv);
00107 void addFrames(const char *directory);
00108 void save(const char *directory);
00109 const char* getAbsolutePath(const char *path);
00110 int checkFiles(const char *directory);
00111 };
00112
00113 #endif