ViewVC Help
View File | Revision Log | Show Annotations | View Changeset | Root Listing
root/OpenMD/trunk/src/utils/simError.h
Revision: 564
Committed: Wed Jul 13 15:54:00 2005 UTC (19 years, 9 months ago) by tim
Content type: text/plain
File size: 1164 byte(s)
Log Message:
replace c++ style comment in c files

File Contents

# User Rev Content
1 gezelter 246
2 gezelter 2 #ifndef __FORTRAN90
3 gezelter 246 #ifndef UTILS_SIMERROR_H
4     #define UTILS_SIMERROR_H
5 gezelter 2
6     #define MAX_SIM_ERROR_MSG_LENGTH 2000
7    
8     #define OOPSE_ERROR 1
9     #define OOPSE_WARNING 2
10     #define OOPSE_INFO 3
11    
12     typedef struct{
13     char errMsg[MAX_SIM_ERROR_MSG_LENGTH];
14     int isFatal;
15     int severity;
16     #ifdef IS_MPI
17     int isEventLoop;
18 tim 564 #endif
19 gezelter 2 } errorStruct;
20    
21     extern errorStruct painCave;
22    
23     #ifdef IS_MPI
24    
25     extern char checkPointMsg[MAX_SIM_ERROR_MSG_LENGTH];
26    
27     extern int worldRank;
28     #endif
29    
30     #ifdef __cplusplus
31     extern "C" {
32 tim 564 #endif
33 gezelter 2
34 tim 564 int simError( void );
35 gezelter 2
36 tim 564 void initSimError( void );
37    
38 gezelter 2
39     #ifdef IS_MPI
40    
41     void MPIcheckPoint( void );
42    
43 tim 564 #endif
44 gezelter 2
45     #ifdef __cplusplus
46     }
47 tim 564 #endif
48 gezelter 2
49 tim 564 #endif
50 gezelter 2
51 tim 564 #else
52 gezelter 2
53     INTEGER, PARAMETER:: OOPSE_ERROR = 1
54     INTEGER, PARAMETER:: OOPSE_WARNING = 2
55     INTEGER, PARAMETER:: OOPSE_INFO = 3
56     INTEGER, PARAMETER:: MAX_SIM_ERROR_MSG_LENGTH = 2000
57    
58 gezelter 507 type, public :: errorStruct
59     PRIVATE
60     SEQUENCE
61     character(len = MAX_SIM_ERROR_MSG_LENGTH) :: errMsg
62     logical :: isFatal
63     integer :: severity
64 gezelter 2 #ifdef IS_MPI
65 gezelter 507 logical :: isEventLoop;
66 tim 564 #endif
67 gezelter 507 end type errorStruct
68 gezelter 2
69 gezelter 507 type (errorStruct), public, save :: painCave
70 gezelter 2
71 tim 564 #endif