CMS 3D CMS Logo

ThingAlgorithm.h
Go to the documentation of this file.
1 #ifndef Integration_ThingAlgorithm_h
2 #define Integration_ThingAlgorithm_h
3 
7 #include "DataFormats/TestObjects/interface/ThingCollectionfwd.h"
8 #include <atomic>
9 
10 namespace edmtest {
12  public:
13  ThingAlgorithm(long iOffsetDelta = 0, int nThings = 20, bool grow = false)
14  : offset_(0), offsetDelta_(iOffsetDelta), nThings_(nThings), grow_(grow) {}
15 
18  void run(ThingCollection& thingCollection) const;
19 
20  private:
21  mutable std::atomic<long> offset_;
22  const long offsetDelta_;
23  const int nThings_;
24  const bool grow_;
25  };
26 
27 } // namespace edmtest
28 
29 #endif
ThingAlgorithm(long iOffsetDelta=0, int nThings=20, bool grow=false)
std::atomic< long > offset_
void run(ThingCollection &thingCollection) const