GSI Object Oriented Online Offline (Go4) GO4-6.4.0
Loading...
Searching...
No Matches
TGo4EventSourceException.cxx
Go to the documentation of this file.
1// $Id$
2//-----------------------------------------------------------------------
3// The GSI Online Offline Object Oriented (Go4) Project
4// Experiment Data Processing at EE department, GSI
5//-----------------------------------------------------------------------
6// Copyright (C) 2000- GSI Helmholtzzentrum fuer Schwerionenforschung GmbH
7// Planckstr. 1, 64291 Darmstadt, Germany
8// Contact: http://go4.gsi.de
9//-----------------------------------------------------------------------
10// This software can be used under the license agreements as stated
11// in Go4License.txt file which is part of the distribution.
12//-----------------------------------------------------------------------
13
15
16#include "TGo4EventSource.h"
17#include "TGo4Log.h"
18
21{
22 GO4TRACE((16,"TGo4EventSourceException::TGo4EventSourceException (TGo4EventSource*)", __LINE__, __FILE__));
23 fxDescription= "!!!-- Go4 EventSource Exception --!!!";
24 if(eventsource) {
25 fxEventSource=eventsource;
26 fxErrMess=eventsource->GetErrMess();
27 fxSourceName=eventsource->GetName();
28 fxSourceClass=eventsource->ClassName();
29 fiCreateStatus=eventsource->GetCreateStatus();
30 fiEventStatus=eventsource->GetEventStatus();
31 }
32}
33
34
37{
38 GO4TRACE((16,"TGo4EventSourceException::TGo4EventSourceException(right)", __LINE__, __FILE__)); ;
40 fxErrMess=right.fxErrMess;
45}
46
48{
49 GO4TRACE((16, "TGo4EventSourceException::operator=", __LINE__, __FILE__));
50 if (&right != this) {
51 TGo4RuntimeException::operator=(right); // copy base class members
53 fxErrMess = right.fxErrMess;
58 }
59 return *this;
60}
61
63{
64 GO4TRACE((16,"TGo4EventSourceException::~TGo4EventSourceException", __LINE__, __FILE__));
65}
66
68{
69 GO4TRACE((12,"TGo4EventSourceException::Handle()", __LINE__, __FILE__));
70
71 TGo4Log::Debug("%s \n %s of name %s: \n\tCreateStatus: %d \n\tEventStatus:%d, \n\t%s",
72 What(),
75
76 return 0;
77}
78
#define GO4TRACE(X)
Definition TGo4Log.h:25
Int_t GetEventStatus() const
Status of the last event.
TString fxSourceName
Name of the throwing event source.
Int_t Handle() override
This is a default handler function for the respective exception type.
Int_t GetCreateStatus() const
Status value of server/file open.
TGo4EventSourceException & operator=(const TGo4EventSourceException &right)
const char * GetSourceClass() const
Name of the throwing event source.
const char * GetSourceName() const
Name of the throwing event source.
const char * GetErrMess() const
Status/ error message of the last event.
Int_t fiEventStatus
Contains return value of eventsource getevent (e.g.
TString fxErrMess
Error message at exception throw time.
Int_t fiCreateStatus
Contains return value of eventsource open (e.g.
TString fxSourceClass
Class of the throwing event source.
const char * GetErrMess() const
Status/ error message of the last event.
Int_t GetEventStatus() const
Status of the last event.
Int_t GetCreateStatus() const
Status value of server/file open.
virtual const char * What()
Returns string describing the kind of exception.
TString fxDescription
static void Debug(const char *text,...) GO4_PRINTF_ARGS
User shortcut for message with prio 0.
Definition TGo4Log.cxx:281
TGo4RuntimeException & operator=(const TGo4RuntimeException &right)