LArSoft  v07_13_02
Liquid Argon Software toolkit - http://larsoft.org/
exception.cc
Go to the documentation of this file.
1 // ======================================================================
2 //
3 // exception
4 //
5 // ======================================================================
6 
7 #include "fhiclcpp/exception.h"
8 
9 // ----------------------------------------------------------------------
10 
11 std::string
13 {
14  switch (code) {
15  case cant_find:
16  return "Can't find key";
17  case cant_happen:
18  return "Can't happen";
19  case cant_insert:
20  return "Can't insert key";
22  return "Excessive value";
23  case parse_error:
24  return "Parse error";
25  case type_mismatch:
26  return "Type mismatch";
28  return "Protection violation";
29  case cant_open_db:
30  return "Can't open DB";
31  case sql_error:
32  return "SQL error";
33  case unimplemented:
34  return "Unimplemented feature";
35  case other:
36  return "Other error";
37  default:
38  return "Unknown code";
39  }
40 }
41 
42 // ======================================================================
std::string translate(error)
Definition: exception.cc:12