10#include <mdst/dbobjects/SoftwareTriggerCutBase.h>
11#include <framework/utilities/GeneralCut.h>
12#include <hlt/softwaretrigger/core/SoftwareTriggerVariableManager.h>
13#include <mdst/dataobjects/SoftwareTriggerResult.h>
22 namespace SoftwareTrigger {
79 static std::unique_ptr<SoftwareTriggerCut>
compile(
const std::string& cut_string,
80 const unsigned int prescaleFactor,
81 const bool rejectCut =
false);
89 return m_cut->decompile();
104 uint32_t* counter =
nullptr)
109 std::unique_ptr<GeneralCut<SoftwareTriggerVariableManager>>
m_cut =
nullptr;
115 unsigned int prescaleFactor,
This class implements a common way to implement cut/selection functionality for arbitrary objects.
Base class for the SoftwareTriggerCut and its DBRepresentation.
Software Trigger Cut to be used in the Software Trigger Modules.
SoftwareTriggerCutResult checkPreScaled(const SoftwareTriggerVariableManager::Object &prefilledObject) const
Main function of the SoftwareTriggerCut: check the cut condition.
std::unique_ptr< GeneralCut< SoftwareTriggerVariableManager > > m_cut
Internal representation of the cut condition as a general cut.
SoftwareTriggerCut(std::unique_ptr< GeneralCut< SoftwareTriggerVariableManager > > &&cut, unsigned int prescaleFactor, const bool rejectCut)
Make constructor private.
std::pair< SoftwareTriggerCutResult, SoftwareTriggerCutResult > check(const SoftwareTriggerVariableManager::Object &prefilledObject, uint32_t *counter=nullptr) const
Return both the prescaled and the non-prescaled result.
static std::unique_ptr< SoftwareTriggerCut > compile(const std::string &cut_string, const unsigned int prescaleFactor, const bool rejectCut=false)
Compile a new SoftwareTriggerCut from a cut string (by using the GeneralCut::compile function) and an...
std::string decompile() const
Decompile the internal General Cut back into a string.
SoftwareTriggerObject Object
As an object handed in for every cut to be checked, use a map of variable name -> precompiled value.
SoftwareTriggerCutResult
Enumeration with all possible results of the SoftwareTriggerCut.
Abstract base class for different kinds of events.