ThePEG
1.8.0
Main Page
Related Pages
Modules
Namespaces
Classes
Files
File List
File Members
Handlers
Hint.h
1
// -*- C++ -*-
2
//
3
// Hint.h is a part of ThePEG - Toolkit for HEP Event Generation
4
// Copyright (C) 1999-2011 Leif Lonnblad
5
//
6
// ThePEG is licenced under version 2 of the GPL, see COPYING for details.
7
// Please respect the MCnet academic guidelines, see GUIDELINES for details.
8
//
9
#ifndef ThePEG_Hint_H
10
#define ThePEG_Hint_H
11
// This is the declaration of the Hint class.
12
13
#include "ThePEG/Config/ThePEG.h"
14
#include "ThePEG/Utilities/ClassDescription.h"
15
16
namespace
ThePEG {
17
48
class
Hint
:
public
Base
{
49
50
public
:
51
57
Hint
() :
theScale
(Energy2()),
theStopFlag
(false) {}
59
60
public
:
61
65
bool
tagged
()
const
{
return
!
theTagged
.empty(); }
66
73
tPVector
tagged
(
const
Step
& s)
const
;
74
78
template
<
typename
InputIterator>
79
void
tag
(InputIterator first, InputIterator last)
80
{
81
theTagged
.insert(
theTagged
.end(), first, last);
82
}
83
87
void
tag
(
tPPtr
p) {
if
(p)
theTagged
.push_back(p); }
88
92
void
stop
(
bool
newStopFlag)
93
{
94
theStopFlag
= newStopFlag;
95
if
(
theStopFlag
)
theTagged
.clear();
96
}
97
101
bool
stop
()
const
{
return
theStopFlag
; }
102
106
void
scale
(
const
Scale
& newScale) {
theScale
= newScale; }
110
const
Scale
&
scale
()
const
{
return
theScale
; }
111
115
static
tHintPtr
Default
() {
return
tHintPtr
(&
theDefaultHint
); }
116
117
public
:
118
125
void
persistentOutput
(
PersistentOStream
& os)
const
;
126
132
void
persistentInput
(
PersistentIStream
& is,
int
version);
134
138
static
void
Init
();
139
140
private
:
141
145
tPVector
theTagged
;
146
150
Scale
theScale
;
151
155
bool
theStopFlag
;
156
160
static
Hint
theDefaultHint
;
161
162
private
:
163
167
static
ClassDescription<Hint>
initHint
;
168
172
Hint
&
operator=
(
const
Hint
& h);
173
174
};
175
176
183
template
<>
184
struct
BaseClassTrait
<
Hint
,1>:
public
ClassTraitsType
{
186
typedef
Base
NthBase
;
187
};
188
193
template
<>
194
struct
ClassTraits<Hint>:
195
public
ClassTraitsBase<Hint> {
197
static
string
className
() {
return
"ThePEG::Hint"
; }
198
};
199
202
}
203
204
#endif
/* ThePEG_Hint_H */
Generated on Sat Jun 16 2012 16:51:04 for ThePEG by
1.8.1.1