BlockIPPlatform
 All Classes Files Functions Variables
ExceptionBlockIPInterface.h
Go to the documentation of this file.
1 
6 #ifndef EXCEPTION_BLOCKIP_INTERFACE
7 #define EXCEPTION_BLOCKIP_INTERFACE
8 
9 #ifndef EXPDLL
10 #ifdef WIN32
11 #ifdef BLOCKIP_INTERFACE_EXPORTS
12 #define EXPDLL __declspec(dllexport)
13 #else
14 #define EXPDLL __declspec(dllimport)
15 #endif //BLOCKIP_INTERFACE_EXPORTS
16 #else
17 #define EXPDLL
18 #endif //WIN32
19 #endif //EXPDLL
20 
21 #include <exception>
22 #include <string>
23 
24 using namespace std;
25 
27 class EXPDLL ExceptionBlockIPInterface : public exception {
28  public:
29  enum TYPE_ERROR {OSI_INTERFACE_NOT_AVAILABLE, SOLVER_NOT_DEFINED, NONLINEAR_NON_ACCEPTED,
30  CREATE_TMP_FILES, OPEN_TMP_FILES, SOLUTION_FILE};
31 
32  TYPE_ERROR error;
33  string file;
34  int line;
35  ExceptionBlockIPInterface(TYPE_ERROR error) throw();
36  ExceptionBlockIPInterface(TYPE_ERROR error, string file, int line) throw();
37  ~ExceptionBlockIPInterface() throw();
38  const char* what() const throw();
39 };
40 
41 #endif //EXCEPTION_BLOCKIP_INTERFACE