CMS 3D CMS Logo

List of all members | Public Member Functions | Static Public Member Functions | Private Member Functions | Private Attributes | Static Private Attributes
gen::FortranCallback Class Reference

#include <FortranCallback.h>

Public Member Functions

void fillEvent ()
 
void fillHeader ()
 
int getIterationsPerEvent () const
 
void resetIterationsPerEvent ()
 
void setLHEEvent (lhef::LHEEvent *lhee)
 
void setLHERunInfo (lhef::LHERunInfo *lheri)
 

Static Public Member Functions

static FortranCallbackgetInstance ()
 

Private Member Functions

 FortranCallback ()
 

Private Attributes

lhef::LHEEventfEventBlock
 
int fIterationsPerEvent
 
lhef::LHERunInfofRunBlock
 

Static Private Attributes

static FortranCallbackfInstance = nullptr
 

Detailed Description

Definition at line 15 of file FortranCallback.h.

Constructor & Destructor Documentation

◆ FortranCallback()

gen::FortranCallback::FortranCallback ( )
inlineprivate

Definition at line 46 of file FortranCallback.h.

48  : fRunBlock(nullptr), fEventBlock(nullptr), fIterationsPerEvent(0) {}

Member Function Documentation

◆ fillEvent()

void gen::FortranCallback::fillEvent ( )
inline

Definition at line 62 of file FortranCallback.h.

62  {
63  //if ( fPartonLevel == 0 ) return;
64  //const lhef::HEPEUP* hepeup = fPartonLevel->getHEPEUP();
65 
66  if (fEventBlock == nullptr)
67  return;
68 
69  const lhef::HEPEUP* hepeup = fEventBlock->getHEPEUP();
70 
71  if (fIterationsPerEvent++) {
72  hepeup_.nup = 0;
73  return;
74  }
75 
77 
78  return;
79  }

References fEventBlock, lhef::CommonBlocks::fillHEPEUP(), fIterationsPerEvent, lhef::LHEEvent::getHEPEUP(), hepeup_, and HEPEUP_::nup.

Referenced by gen::Pythia6ServiceWithCallback::upEvnt().

◆ fillHeader()

void gen::FortranCallback::fillHeader ( )
inline

Definition at line 50 of file FortranCallback.h.

50  {
51  if (fRunBlock == nullptr)
52  return;
53 
54  //const lhef::HEPRUP* heprup = &(fRunBlock->heprup());
55  const lhef::HEPRUP* heprup = fRunBlock->getHEPRUP();
56 
58 
59  return;
60  }

References lhef::CommonBlocks::fillHEPRUP(), fRunBlock, and lhef::LHERunInfo::getHEPRUP().

Referenced by gen::Pythia6ServiceWithCallback::upInit().

◆ getInstance()

FortranCallback * gen::FortranCallback::getInstance ( )
static

◆ getIterationsPerEvent()

int gen::FortranCallback::getIterationsPerEvent ( ) const
inline

Definition at line 28 of file FortranCallback.h.

28 { return fIterationsPerEvent; }

References fIterationsPerEvent.

◆ resetIterationsPerEvent()

void gen::FortranCallback::resetIterationsPerEvent ( )
inline

◆ setLHEEvent()

void gen::FortranCallback::setLHEEvent ( lhef::LHEEvent lhee)
inline

Definition at line 21 of file FortranCallback.h.

21 { fEventBlock = lhee; }

References fEventBlock.

Referenced by gen::Pythia6Hadronizer::hadronize().

◆ setLHERunInfo()

void gen::FortranCallback::setLHERunInfo ( lhef::LHERunInfo lheri)
inline

Definition at line 20 of file FortranCallback.h.

20 { fRunBlock = lheri; }

References fRunBlock.

Referenced by gen::Pythia6Hadronizer::initializeForExternalPartons().

Member Data Documentation

◆ fEventBlock

lhef::LHEEvent* gen::FortranCallback::fEventBlock
private

Definition at line 38 of file FortranCallback.h.

Referenced by fillEvent(), and setLHEEvent().

◆ fInstance

FortranCallback * gen::FortranCallback::fInstance = nullptr
staticprivate

Definition at line 41 of file FortranCallback.h.

Referenced by getInstance().

◆ fIterationsPerEvent

int gen::FortranCallback::fIterationsPerEvent
private

Definition at line 39 of file FortranCallback.h.

Referenced by fillEvent(), getIterationsPerEvent(), and resetIterationsPerEvent().

◆ fRunBlock

lhef::LHERunInfo* gen::FortranCallback::fRunBlock
private

Definition at line 37 of file FortranCallback.h.

Referenced by fillHeader(), and setLHERunInfo().

lhef::LHEEvent::getHEPEUP
const HEPEUP * getHEPEUP() const
Definition: LHEEvent.h:38
gen::FortranCallback
Definition: FortranCallback.h:15
gen::FortranCallback::fEventBlock
lhef::LHEEvent * fEventBlock
Definition: FortranCallback.h:38
lhef::CommonBlocks::fillHEPEUP
static void fillHEPEUP(const HEPEUP *hepeup)
Definition: LHECommonBlocks.h:60
hepeup_
struct HEPEUP_ hepeup_
lhef::CommonBlocks::fillHEPRUP
static void fillHEPRUP(const HEPRUP *heprup)
Definition: LHECommonBlocks.h:41
lhef::HEPRUP
Definition: LesHouches.h:22
lhef::HEPEUP
Definition: LesHouches.h:138
lhef::LHERunInfo::getHEPRUP
const HEPRUP * getHEPRUP() const
Definition: LHERunInfo.h:51
gen::FortranCallback::fInstance
static FortranCallback * fInstance
Definition: FortranCallback.h:41
HEPEUP_::nup
int nup
Definition: LHECommonBlocks.h:21
gen::FortranCallback::fRunBlock
lhef::LHERunInfo * fRunBlock
Definition: FortranCallback.h:37
gen::FortranCallback::fIterationsPerEvent
int fIterationsPerEvent
Definition: FortranCallback.h:39