~chris-rogers/maus/emr_mc_digitization

« back to all changes in this revision

Viewing changes to src/common_cpp/API/ModuleBase.cc

  • Committer: Chris Rogers
  • Date: 2014-04-16 11:48:45 UTC
  • mfrom: (707 merge)
  • mto: This revision was merged to the branch mainline in revision 711.
  • Revision ID: chris.rogers@stfc.ac.uk-20140416114845-h3u3q7pdcxkxvovs
Update to trunk

Show diffs side-by-side

added added

removed removed

Lines of Context:
16
16
 */
17
17
#include "src/common_cpp/API/ModuleBase.hh"
18
18
#include "src/common_cpp/API/APIExceptions.hh"
19
 
#include "src/legacy/Interface/Squeal.hh"
 
19
#include "Utils/Exception.hh"
20
20
#include "src/common_cpp/Utils/CppErrorHandler.hh"
21
21
 
22
22
namespace MAUS {
29
29
    try {
30
30
      _birth(s);
31
31
    }
32
 
    catch(Squeal& s) {
33
 
      CppErrorHandler::getInstance()->HandleSquealNoJson(s, _classname);
 
32
    catch (Exception& s) {
 
33
      CppErrorHandler::getInstance()->HandleExceptionNoJson(s, _classname);
34
34
    }
35
 
    catch(std::exception & e) {
 
35
    catch (std::exception & e) {
36
36
      CppErrorHandler::getInstance()->HandleStdExcNoJson(e, _classname);
37
37
    }
38
 
    catch(...) {
 
38
    catch (...) {
39
39
      throw UnhandledException(_classname);
40
40
    }
41
41
  }
44
44
    try {
45
45
      _death();
46
46
    }
47
 
    catch(Squeal& s) {
48
 
      CppErrorHandler::getInstance()->HandleSquealNoJson(s, _classname);
 
47
    catch (Exception& s) {
 
48
      CppErrorHandler::getInstance()->HandleExceptionNoJson(s, _classname);
49
49
    }
50
 
    catch(std::exception & e) {
 
50
    catch (std::exception & e) {
51
51
      CppErrorHandler::getInstance()->HandleStdExcNoJson(e, _classname);
52
52
    }
53
 
    catch(...) {
 
53
    catch (...) {
54
54
      throw UnhandledException(_classname);
55
55
    }
56
56
  }