Mēnsūra
Public Member Functions | List of all members
GeneratorReader Class Referenceabstract

Abstract base class for a reader plugin that provides process-level generator information. More...

#include <GeneratorReader.hpp>

Inheritance diagram for GeneratorReader:
ReaderPlugin Plugin PECGeneratorReader

Public Member Functions

 GeneratorReader (std::string const name="Generator")
 Creates plugin with the given name. More...
 
virtual double GetAltWeight (unsigned index) const
 Returns alternative LHE-level weight with the given index. More...
 
virtual double GetNominalWeight () const =0
 Returns nominal LHE-level weight for the current event.
 
virtual unsigned GetNumAltWeights () const
 Returns number of available alternative weights. More...
 
- Public Member Functions inherited from ReaderPlugin
 ReaderPlugin (std::string const &name)
 Constructor.
 
 ReaderPlugin (ReaderPlugin const &)=default
 Default copy constructor.
 
 ReaderPlugin (ReaderPlugin &&)=default
 Default move constructor.
 
ReaderPluginoperator= (ReaderPlugin const &)=default
 Default assignment operator.
 
virtual ~ReaderPlugin ()
 Trivial destructor.
 
- Public Member Functions inherited from Plugin
 Plugin (std::string const &name)
 Constructor.
 
 Plugin (Plugin const &)=default
 Default copy constructor.
 
 Plugin (Plugin &&)=default
 Default move constructor.
 
Pluginoperator= (Plugin const &)=default
 Default assignment operator.
 
virtual ~Plugin ()
 Trivial destructor.
 
virtual void BeginRun (Dataset const &dataset)
 Performs initialization needed when processing of a new dataset starts. More...
 
virtual PluginClone () const =0
 Clones the object. More...
 
virtual void EndRun ()
 Performs necessary actions needed after processing of a dataset is finished. More...
 
Processor const & GetMaster () const
 Returns a reference to the master. More...
 
std::string const & GetName () const
 Returns name of the plugin.
 
EventOutcome ProcessEventToOutcome ()
 Processes a new event from the current dataset. More...
 
void SetMaster (Processor const *processor)
 Provides a pointer to an instance of Processor class that owns the plugin. More...
 

Additional Inherited Members

- Public Types inherited from Plugin
enum  EventOutcome { EventOutcome::Ok, EventOutcome::FilterFailed, EventOutcome::NoEvents }
 Outcome of processing of an event. More...
 
- Protected Member Functions inherited from Plugin
Plugin const * GetDependencyPlugin (std::string const &name) const
 Returns a pointer to a precedent plugin in the path with the given name. More...
 

Detailed Description

Abstract base class for a reader plugin that provides process-level generator information.

Provides an interface to access nominal and alternative generator-level event weights.

Constructor & Destructor Documentation

GeneratorReader::GeneratorReader ( std::string const  name = "Generator")

Creates plugin with the given name.

User is encouraged to keep the default name.

Member Function Documentation

double GeneratorReader::GetAltWeight ( unsigned  index) const
virtual

Returns alternative LHE-level weight with the given index.

Unconditionally throws an exception in the default implementation.

Reimplemented in PECGeneratorReader.

unsigned GeneratorReader::GetNumAltWeights ( ) const
virtual

Returns number of available alternative weights.

In the default implementation this number is always zero.

Reimplemented in PECGeneratorReader.


The documentation for this class was generated from the following files: