Line data Source code
1 : /// Including DBE
2 : #include "dbe/MyApplication.hpp"
3 : #include "dbe/Exceptions.hpp"
4 : /// Including TDAq
5 : #include "conffwk/Configuration.hpp"
6 : #include "ers/ers.hpp"
7 : #include "logging/Logging.hpp"
8 :
9 : #include "dbe/messenger.hpp"
10 : #include "dbe/version.hpp"
11 :
12 : char const * const dbe_lib_core_version = dbe_compiled_version;
13 :
14 0 : bool dbe::MyApplication::notify ( QObject * rec, QEvent * ev )
15 : {
16 0 : HERE_AUTO_DEF ( notify );
17 :
18 0 : try
19 : {
20 0 : return QApplication::notify ( rec, ev );
21 : }
22 0 : catch ( dunedaq::conffwk::Exception const & err )
23 : {
24 0 : TLOG() << "MyApplication: dunedaq::conffwk::Exception: " << err ;
25 0 : ERROR ( "Unexpected error occurred", dbe::config::errors::unwind(err), "dunedaq::conffwk::Exception caught at", HERE );
26 0 : return false;
27 0 : }
28 0 : catch ( ers::Issue const & err )
29 : {
30 0 : TLOG() << "MyApplication: ers::Issue: " << err ;
31 0 : ERROR ( "ers::Issue occurred", dbe::config::errors::unwind(err), "\n\nCaught at:", HERE );
32 0 : return false;
33 0 : }
34 0 : catch ( std::exception const & err )
35 : {
36 0 : TLOG() << "MyApplication: std::exception: " ;
37 0 : ERROR ( "Error sending event", err.what(), "for object", typeid ( *ev ).name(), "Receiver",
38 0 : typeid ( *rec ).name() );
39 0 : return false;
40 0 : }
41 0 : catch ( char const * str )
42 : {
43 0 : TLOG() << "MyApplication: EXCEPTION: " << str << std::endl ;
44 0 : ERROR ( "Unknown exception", str, "\n\nCaught at: ", HERE );
45 0 : return false;
46 0 : }
47 0 : catch ( ... )
48 : {
49 0 : TLOG_DEBUG(0) << "MyApplication: Unknown exception!" ;
50 0 : ERROR ( "Unknown exception", "\n\nCaught at: ", HERE );
51 0 : return false;
52 0 : }
53 :
54 : TLOG() << "MyApplication: outside catch..." ;
55 : return false;
56 : }
|