thepeg is hosted by Hepforge, IPPP Durham
ThePEG 2.3.0
ThePEG.h
Go to the documentation of this file.
1// -*- C++ -*-
2//
3// ThePEG.h is a part of ThePEG - Toolkit for HEP Event Generation
4// Copyright (C) 1999-2019 Leif Lonnblad
5//
6// ThePEG is licenced under version 3 of the GPL, see COPYING for details.
7// Please respect the MCnet academic guidelines, see GUIDELINES for details.
8//
9#ifndef ThePEG_H
10#define ThePEG_H
11
19#ifndef ThePEG_ALTERNATE_CONFIG
20
21#include "ThePEG/Pointer/Ptr.h"
22#include "ThePEG/Pointer/PtrTraits.h"
23#include "ThePEG/Pointer/RCPtr.h"
24#include "ThePEG/Utilities/Rebinder.fh"
25#include "ThePEG/Utilities/Interval.fh"
26#include "ThePEG/Utilities/ClassDescription.fh"
27#include "ThePEG/Interface/InterfaceBase.fh"
28#include "ThePEG/Persistency/PersistentOStream.fh"
29#include "ThePEG/Persistency/PersistentIStream.fh"
30#include "TemplateTools.h"
31#include "Complex.h"
32#include "Unitsystem.h"
33#include "Constants.h"
34#include "std.h"
35
36
43namespace ThePEG {
44
45// Introduce some identifiers in the ThePEG namespace/
46using namespace ThePEG::Pointer;
48using namespace ThePEG::Units;
49
54struct Base: public ReferenceCounted {
55
57 virtual ~Base() {}
58
65 static void Init() {}
66
72 void debug() const;
73
78 virtual void debugme() const;
79
80};
81
87
94struct TraitsType {};
95
99struct Veto {
100
103};
104
109struct Stop {};
110
115template <typename T>
116inline constexpr
117auto sqr(const T& x) -> decltype(x*x) {
118 return x*x;
119}
120
121// Debugging in ThePEG may be swithced off completely by this
122// compilation swithc, eliminating possible overhead in error
123// checking.
124#ifndef ThePEG_NO_DEBUG
126#define ThePEG_DEBUG_LEVEL Debug::level
128#define ThePEG_DEBUG_ITEM(item) Debug::debugItem(item)
129#else
131#define ThePEG_DEBUG_LEVEL 0
133#define ThePEG_DEBUG_ITEM(item) false
134#endif
135
136}
137
138#include "Pointers.h"
139#include "Containers.h"
140
141#else
142
143#include ThePEG_ALTERNATIVE_CONFIG
144
145#endif
146
147#endif /* ThePEG_H */
148
This file defines a number of containers.
This file declares typedefs of commonly used pointers in ThePEG.
Useful template machinery.
ReferenceCounted must be the (virtual) base class of all classes which may be pointed to by the RCPtr...
The namespace for the reference counted pointer classes.
Definition: Ptr.h:18
The Units namespace contains the declaration of a number of classes for variables with dimension.
Definition: Unitsystem.h:35
This is the main namespace within which all identifiers in ThePEG are declared.
Definition: FactoryBase.h:28
Base PersistentBase
Define the base class from which all persistent classes in ThePEG are derived.
Definition: ThePEG.h:86
constexpr auto sqr(const T &x) -> decltype(x *x)
The square function should really have been included in the standard C++ library.
Definition: ThePEG.h:117
This file introduces a number of std:: classes into the ThePEG namespace.
Define the base class from which all (polymorphic) classes in ThePEG are derived.
Definition: ThePEG.h:54
virtual void debugme() const
Print out debugging information for this object on std::cerr.
void debug() const
Print out debugging information for this object on std::cerr.
static void Init()
The standard Init function used to initialize the interfaces.
Definition: ThePEG.h:65
virtual ~Base()
The virtual destructor.
Definition: ThePEG.h:57
Ptr is a templated class to provide typedefs for pointers types ThePEG should use for a given type.
Definition: Ptr.h:35
A standard exception class to be used to temporarily stop the generation of an event.
Definition: ThePEG.h:109
TraitsType is an empty, non-polymorphic, base class.
Definition: ThePEG.h:94
A standard exception class to be used for vetoing a whole event.
Definition: ThePEG.h:99
Veto()
the default constructor.