|
|
|||
File indexing completed on 2026-08-06 09:38:20
0001 // -*- C++ -*- 0002 // 0003 // ThePEG.h is a part of ThePEG - Toolkit for HEP Event Generation 0004 // Copyright (C) 1999-2019 Leif Lonnblad 0005 // 0006 // ThePEG is licenced under version 3 of the GPL, see COPYING for details. 0007 // Please respect the MCnet academic guidelines, see GUIDELINES for details. 0008 // 0009 #ifndef ThePEG_H 0010 #define ThePEG_H 0011 0012 /** \file ThePEG.h 0013 * This is the main config header file for ThePEG. Do not make 0014 * changes in this file. If you need to modify anything, edit a copy 0015 * of the file which can be included instead of this file using the 0016 * macro <code>ThePEG_ALTERNATE_CONFIG</code>. 0017 */ 0018 0019 #ifndef ThePEG_ALTERNATE_CONFIG 0020 0021 #include "ThePEG/Pointer/Ptr.h" 0022 #include "ThePEG/Pointer/PtrTraits.h" 0023 #include "ThePEG/Pointer/RCPtr.h" 0024 #include "ThePEG/Utilities/Rebinder.fh" 0025 #include "ThePEG/Utilities/Interval.fh" 0026 #include "ThePEG/Utilities/ClassDescription.fh" 0027 #include "ThePEG/Interface/InterfaceBase.fh" 0028 #include "ThePEG/Persistency/PersistentOStream.fh" 0029 #include "ThePEG/Persistency/PersistentIStream.fh" 0030 #include "TemplateTools.h" 0031 #include "Complex.h" 0032 #include "Unitsystem.h" 0033 #include "Constants.h" 0034 #include "std.h" 0035 0036 0037 /** 0038 * This is the main namespace within which all identifiers in ThePEG 0039 * are declared. External packages based on ThePEG should not 0040 * introduce identifiers in the ThePEG namespace, but in a separate 0041 * namespace which need not be nested within the ThePEG namespace. 0042 */ 0043 namespace ThePEG { 0044 0045 // Introduce some identifiers in the ThePEG namespace/ 0046 using namespace ThePEG::Pointer; 0047 using ThePEG::Pointer::Ptr; 0048 using namespace ThePEG::Units; 0049 0050 /** 0051 * Define the base class from which all (polymorphic) classes in 0052 * ThePEG are derived. 0053 */ 0054 struct Base: public ReferenceCounted { 0055 0056 /** The virtual destructor */ 0057 virtual ~Base() {} 0058 0059 /** 0060 * The standard Init function used to initialize the interfaces. 0061 * Called exactly once for each class by the class description system 0062 * before the main function starts or 0063 * when this class is dynamically loaded. 0064 */ 0065 static void Init() {} 0066 0067 /** 0068 * Print out debugging information for this object on std::cerr. To 0069 * be called from within a debugger. Simply calls the virtual 0070 * debugme() function. 0071 */ 0072 void debug() const; 0073 0074 /** 0075 * Print out debugging information for this object on std::cerr. To 0076 * be called from within a debugger via the debug() function. 0077 */ 0078 virtual void debugme() const; 0079 0080 }; 0081 0082 /** 0083 * Define the base class from which all persistent classes in 0084 * ThePEG are derived. 0085 */ 0086 typedef Base PersistentBase; 0087 0088 /** 0089 * TraitsType is an empty, non-polymorphic, base class. It is used as 0090 * a base class of all traits classes in ThePEG in order to group them 0091 * together in the documentation. It currently serves no other 0092 * purpose. 0093 */ 0094 struct TraitsType {}; 0095 0096 /** 0097 * A standard exception class to be used for vetoing a whole event. 0098 */ 0099 struct Veto { 0100 0101 /** the default constructor. */ 0102 Veto(); 0103 }; 0104 0105 /** 0106 * A standard exception class to be used to temporarily stop the 0107 * generation of an event. 0108 */ 0109 struct Stop {}; 0110 0111 /** 0112 * The square function should really have been included in the 0113 * standard C++ library. 0114 */ 0115 template <typename T> 0116 inline constexpr 0117 auto sqr(const T& x) -> decltype(x*x) { 0118 return x*x; 0119 } 0120 0121 // Debugging in ThePEG may be swithced off completely by this 0122 // compilation swithc, eliminating possible overhead in error 0123 // checking. 0124 #ifndef ThePEG_NO_DEBUG 0125 /** Macro for accessing debug functions to enable compile-time disabling. */ 0126 #define ThePEG_DEBUG_LEVEL Debug::level 0127 /** Macro for accessing debug functions to enable compile-time disabling. */ 0128 #define ThePEG_DEBUG_ITEM(item) Debug::debugItem(item) 0129 #else 0130 /** Macro for accessing debug functions to enable compile-time disabling. */ 0131 #define ThePEG_DEBUG_LEVEL 0 0132 /** Macro for accessing debug functions to enable compile-time disabling. */ 0133 #define ThePEG_DEBUG_ITEM(item) false 0134 #endif 0135 0136 } 0137 0138 #include "Pointers.h" 0139 #include "Containers.h" 0140 0141 #else 0142 0143 #include ThePEG_ALTERNATIVE_CONFIG 0144 0145 #endif 0146 0147 #endif /* ThePEG_H */ 0148
| [ Source navigation ] | [ Diff markup ] | [ Identifier search ] | [ general search ] |
|
This page was automatically generated by the 2.3.7 LXR engine. The LXR team |
|