Rivet.hh
Go to the documentation of this file.
00001 #ifndef RIVET_Rivet_HH 00002 #define RIVET_Rivet_HH 00003 00004 #include "Rivet/Config/RivetConfig.hh" 00005 #include "Rivet/Config/BuildOptions.hh" 00006 00007 // Bring selected STL classes into the Rivet namespace 00008 #include "Rivet/Tools/RivetSTL.hh" 00009 00010 // Macro to help with overzealous compiler warnings 00011 #ifdef UNUSED 00012 #elif defined(__GNUC__) 00013 # define UNUSED(x) UNUSED_ ## x __attribute__((unused)) 00014 #elif defined(__LCLINT__) 00015 # define UNUSED(x) /*@unused@*/ x 00016 #else 00017 # define UNUSED(x) x 00018 #endif 00019 00020 00021 namespace Rivet { 00022 00023 /// A sensible default maximum value of rapidity for Rivet analyses to use. 00024 static const double MAXRAPIDITY = 100000.0; 00025 00026 /// A function to get the Rivet version string 00027 string version(); 00028 00029 } 00030 00031 // HepMC headers and helper functions 00032 #include "Rivet/Tools/RivetHepMC.hh" 00033 00034 // Now import some Rivet classes 00035 #include "Rivet/Exceptions.hh" 00036 #include "Rivet/Math/MathUtils.hh" 00037 #include "Rivet/Math/Vectors.hh" 00038 #include "Rivet/Math/Matrices.hh" 00039 #include "Rivet/Math/Units.hh" 00040 #include "Rivet/Tools/Utils.hh" 00041 #include "Rivet/Tools/RivetPaths.hh" 00042 00043 #include "Rivet/ParticleName.hh" 00044 #include "Rivet/Particle.hh" 00045 00046 00047 namespace Rivet { 00048 00049 00050 /// Convenient function for streaming out vectors of any streamable object. 00051 template<typename T> 00052 inline std::ostream& operator<<(std::ostream& os, const std::vector<T>& vec) { 00053 os << "[ "; 00054 for (size_t i=0; i<vec.size(); ++i) { 00055 os << vec[i] << " "; 00056 } 00057 os << "]"; 00058 return os; 00059 } 00060 00061 00062 /// Convenient function for streaming out lists of any streamable object. 00063 template<typename T> 00064 inline std::ostream& operator<<(std::ostream& os, const std::list<T>& vec) { 00065 os << "[ "; 00066 for (size_t i=0; i<vec.size(); ++i) { 00067 os << vec[i] << " "; 00068 } 00069 os << "]"; 00070 return os; 00071 } 00072 00073 00074 } 00075 00076 #endif Generated on Fri Oct 25 2013 12:41:47 for The Rivet MC analysis system by ![]() |