Go to the documentation of this file.00001
00002 #ifdef __ICC
00003
00004
00005 #pragma warning(disable:2259)
00006 #endif
00007 #ifdef WIN32
00008
00009
00010
00011 #pragma warning(disable:4996)
00012 #endif
00013
00014
00015
00016
00017
00018 #include "GaudiKernel/Kernel.h"
00019
00020 #include <string>
00021 #include <vector>
00023 #define class class GAUDI_API
00024 #include "AIDA/IHistogram1D.h"
00025 #include "AIDA/IHistogram2D.h"
00026 #include "AIDA/IHistogram3D.h"
00027 #include "AIDA/IProfile1D.h"
00028 #include "AIDA/IProfile2D.h"
00029 #undef class
00030
00031
00032
00033 #include "TH1D.h"
00034 #include "TH2D.h"
00035 #include "TH3D.h"
00036 #include "TProfile.h"
00037 #include "TProfile2D.h"
00038
00039
00040
00041 #include "GaudiKernel/HistogramBase.h"
00042
00043
00044
00045 #include "GaudiUtils/Aida2ROOT.h"
00046
00052
00053
00054
00055 TH1D* Gaudi::Utils::Aida2ROOT::aida2root ( AIDA::IHistogram1D* aida )
00056 {
00057 if ( 0 == aida ) { return 0 ; }
00058 Gaudi::HistogramBase* base = dynamic_cast<Gaudi::HistogramBase*> ( aida ) ;
00059 if ( 0 == base ) { return 0 ; }
00060 return dynamic_cast<TH1D*>( base->representation() ) ;
00061 }
00062
00063
00064
00065 TH2D* Gaudi::Utils::Aida2ROOT::aida2root ( AIDA::IHistogram2D* aida )
00066 {
00067 if ( 0 == aida ) { return 0 ; }
00068 Gaudi::HistogramBase* base = dynamic_cast<Gaudi::HistogramBase*> ( aida ) ;
00069 if ( 0 == base ) { return 0 ; }
00070 return dynamic_cast<TH2D*>( base->representation() ) ;
00071 }
00072
00073
00074
00075 TH3D* Gaudi::Utils::Aida2ROOT::aida2root ( AIDA::IHistogram3D* aida )
00076 {
00077 if ( 0 == aida ) { return 0 ; }
00078 Gaudi::HistogramBase* base = dynamic_cast<Gaudi::HistogramBase*> ( aida ) ;
00079 if ( 0 == base ) { return 0 ; }
00080 return dynamic_cast<TH3D*>( base->representation() ) ;
00081 }
00082
00083
00084
00085 TProfile* Gaudi::Utils::Aida2ROOT::aida2root ( AIDA::IProfile1D* aida )
00086 {
00087 if ( 0 == aida ) { return 0 ; }
00088 Gaudi::HistogramBase* base = dynamic_cast<Gaudi::HistogramBase*> ( aida ) ;
00089 if ( 0 == base ) { return 0 ; }
00090 return dynamic_cast<TProfile*>( base->representation() ) ;
00091 }
00092
00093
00094
00095 TProfile2D* Gaudi::Utils::Aida2ROOT::aida2root ( AIDA::IProfile2D* aida )
00096 {
00097 if ( 0 == aida ) { return 0 ; }
00098 Gaudi::HistogramBase* base = dynamic_cast<Gaudi::HistogramBase*> ( aida ) ;
00099 if ( 0 == base ) { return 0 ; }
00100 return dynamic_cast<TProfile2D*>( base->representation() ) ;
00101 }
00102
00103
00104
00105 TObject* Gaudi::Utils::Aida2ROOT::aida2root ( AIDA::IHistogram* aida )
00106 {
00107 if ( 0 == aida ) { return 0 ; }
00108 Gaudi::HistogramBase* base = dynamic_cast<Gaudi::HistogramBase*> ( aida ) ;
00109 if ( 0 == base ) { return 0 ; }
00110 return base->representation() ;
00111 }
00112
00113
00114