ATLAS Offline Software
Loading...
Searching...
No Matches
RepeatedCondition.h
Go to the documentation of this file.
1/*
2 Copyright (C) 2002-2021 CERN for the benefit of the ATLAS collaboration
3*/
4
5#ifndef TRIGHLTJETHYPO_REPEATEDCONDITION_H
6#define TRIGHLTJETHYPO_REPEATEDCONDITION_H
7
8/********************************************************************
9 *
10 * NAME: RepeatedCondition.h
11 * PACKAGE: Trigger/TrigHypothesis/TrigHLTJetHypo
12 *
13 * AUTHOR: P. Sherwood
14 *
15 * an implementation of the IRepeatedCondition PABC.
16 *
17 *********************************************************************/
18
20#include "IRepeatedCondition.h"
21
22#include <memory>
23#include <string>
24#include <ostream>
25
26
28
30 public:
31 RepeatedCondition(std::unique_ptr<ICondition> cp,
32 std::size_t mult,
33 int clique,
34 int chainPartind = -1,
35 bool invert=false);
36 virtual ~RepeatedCondition();
37
38 virtual bool
39 multiplicitySatisfied(std::size_t jgMultiplicity,
40 const Collector&) const override;
41 virtual bool
43 const std::unique_ptr<ITrigJetHypoInfoCollector>& c) const override;
44
45
46 // capacity: this is the size of a jet group which is requred to
47 // satisfy a Condition.
48 // eg the five ComoundConditions for the chain 3JX_2JX have capcity 1
49 // A Dijet Condition will have multiplicity 2.
50
51
52 virtual unsigned int capacity() const override;
53
54 // multiplicity: RepeatedConditions which contain CompoundConditions
55 // with identical functionality will have the multiplicity
56 // given by the chainPart of the condiguriung chainDict.
57 //
58 // eg the two conditions for the chain 3JX_2JX will have multiplicty
59 // of 3 and 2 respectively.
60 virtual std::size_t multiplicity() const override;
61
62 // clique: RepeatedConditions which contain CompoundConditions
63 // with identical functionality form a clique, and receive
64 // the same value for their clique index.
65 //
66 // eg the two RepeteadConditions for the chain 3JX_2JX form a clique.
67 virtual int clique() const override;
68
69 virtual std::string toString() const override;
70
71 virtual int label() const override;
72
73 virtual bool isFromChainPart() const override;
74
75private:
76
77 std::unique_ptr<ICondition> m_condition;
78 std::size_t m_multiplicity{1};
79 int m_clique{-1};
80 // record of which chain part in the chainDict this conditions comes from
82 bool m_invert{false};
83};
84
85std::ostream& operator<<(std::ostream&,
86 const RepeatedCondition&);
87
88#endif
std::unique_ptr< ITrigJetHypoInfoCollector > Collector
Definition FastReducer.h:22
std::vector< pHypoJet > HypoJetVector
Definition HypoJetDefs.h:27
std::ostream & operator<<(std::ostream &, const RepeatedCondition &)
virtual int label() const override
RepeatedCondition(std::unique_ptr< ICondition > cp, std::size_t mult, int clique, int chainPartind=-1, bool invert=false)
virtual bool isSatisfied(const HypoJetVector &v, const std::unique_ptr< ITrigJetHypoInfoCollector > &c) const override
virtual std::string toString() const override
virtual std::size_t multiplicity() const override
virtual unsigned int capacity() const override
virtual bool isFromChainPart() const override
virtual bool multiplicitySatisfied(std::size_t jgMultiplicity, const Collector &) const override
virtual int clique() const override
std::unique_ptr< ICondition > m_condition
std::size_t m_multiplicity