CLHEP VERSION Reference Documentation
   
CLHEP Home Page     CLHEP Documentation     CLHEP Bug Reports

Exceptions/ZMexSeverity.h
Go to the documentation of this file.
1 #ifndef ZMEXSEVERITY_H
2 #define ZMEXSEVERITY_H
3 
4 
5 // ----------------------------------------------------------------------
6 //
7 // ZMexSeverity.h - define severity codes & ancillary information
8 //
9 // Revision History:
10 // 970917 WEB Updated per code review 2
11 // 971006 WEB Added ZMexSeverityLimit to support limiting
12 // logging by severity
13 // 971016 WEB Added explanations of the various severity levels
14 // 971112 WEB Updated for conformance to standard and the zoom
15 // compatability headers
16 // 980615 WEB Added namespace support
17 // 000217 WEB Improve C++ standards compliance
18 // 000503 WEB Avoid global using
19 // 031105 LG Get rid of all ZMutility references
20 //
21 // ----------------------------------------------------------------------
22 
23 #ifndef STRING_INCLUDED
24  #define STRING_INCLUDED
25  #include <string>
26 #endif
27 
28 
29 namespace zmex {
30 
31 
33 
34  ZMexNORMAL,
35  // All is well; always safe to ignore; typically not worth logging
36  // since it's probably just a temporary placeholder.
37  ZMexINFO,
38  // In the normal course of events, here is news worth logging;
39  // always safe to ignore; often useful for progress reporting and
40  // for debugging purposes.
42  // Something unusual has happened, but we have a quite reasonable
43  // action to take; it's generally safe to ignore the warning because
44  // you'll probably get just about the result you intended; logging
45  // can probably cease after (say) 50 of the same warnings.
46  ZMexERROR,
47  // We encountered something such that, although we can make it safe
48  // to continue running (e.g., by supplying a default value instead of
49  // a value we can't for some reason calculate), you probably won't
50  // get the result you expected unless you handle this yourself; ought
51  // always be logged (but may be sensible, if hundreds of the same
52  // error are intentionally ignored, to stop logging each one).
53  ZMexSEVERE,
54  // The action you intended will almost certainly have a seriously
55  // flawed outcome and we doubt that either we or you can make it safe
56  // to continue if you ignore this; ought always be logged.
57  ZMexFATAL,
58  // We can make no representations as to the state of any part of the
59  // software, even of software parts not obviously associated with the
60  // failed intended action and even if you try to handle the problem;
61  // ought always be logged and essentially never be ignored.
63  // The software has reached a logically impossible internal state;
64  // must always be logged and never be ignored; if encountered, should
65  // always be reported to the software's developers and/or maintainers.
67  // Not a true severity level; useful to count the number of distinct
68  // severity levels and, as such, must always be physically last
69  // within this enum's definition.
70 
71 }; // ZMexSeverity
72 
73 
74 extern const std::string ZMexSeverityName[ ZMexSEVERITYenumLAST ];
75 
77 
79 
80 
81 } // namespace zmex
82 
83 
84 #endif // ZMEXSEVERITY_H
int ZMexSeverityLimit[ZMexSEVERITYenumLAST]
const char ZMexSeverityLetter[ZMexSEVERITYenumLAST]
const std::string ZMexSeverityName[ZMexSEVERITYenumLAST]