Marlin  1.17.1
 All Classes Namespaces Functions Variables Enumerations Friends Pages
Exceptions.h
1 #ifndef Exceptions_h
2 #define Exceptions_h 1
3 
4 #include "lcio.h"
5 #include "Processor.h"
6 
7 // define some exceptions for Marlin
8 
9 namespace marlin{
10 
16  class ParseException : public lcio::Exception{
17 
18  protected:
19  ParseException() { /*no_op*/ ; }
20  public:
21  virtual ~ParseException() throw() { /*no_op*/; }
22 
23  ParseException( std::string text ){
24  message = "marlin::ParseException: " + text ;
25  }
26  };
27 
28 // class Processor ;
29 
34  class SkipEventException : public lcio::Exception{
35 
36  protected:
37  SkipEventException() { /*no_op*/ ; }
38 
39  public:
40  SkipEventException(const Processor* proc){
41  message = proc->name() ;
42  }
43  virtual ~SkipEventException() throw() { /*no_op*/; }
44 
45  };
46 
52  class StopProcessingException : public lcio::Exception{
53 
54  protected:
55  StopProcessingException() { /*no_op*/ ; }
56 
57  public:
59  message = proc->name() ;
60  }
61  virtual ~StopProcessingException() throw() { /*no_op*/; }
62 
63  };
64 
70  class RewindDataFilesException : public lcio::Exception{
71 
72  protected:
73  RewindDataFilesException() { /*no_op*/ ; }
74 
75  public:
77  message = proc->name() ;
78  }
79  virtual ~RewindDataFilesException() throw() { /*no_op*/; }
80 
81  };
82 
83 
84 
85 } // end namespace
86 
87 #endif
88 
89 
90 
RewindDataFilesException used to stop the current proccessing of events, rewind to the first event an...
Definition: Exceptions.h:70
virtual const std::string & name() const
Return name of this processor.
Definition: Processor.h:132
ParseException used for parse errors, e.g.
Definition: Exceptions.h:16
SkipEventException used to skip the current event in Processor::processEvent.
Definition: Exceptions.h:34
StopProcessingException used to stop the current proccessing of events and call Processor::end().
Definition: Exceptions.h:52
Base class for Marlin processors.
Definition: Processor.h:64