CMS 3D CMS Logo

FunctorTask.h
Go to the documentation of this file.
1 #ifndef FWCore_Concurrency_FunctorTask_h
2 #define FWCore_Concurrency_FunctorTask_h
3 // -*- C++ -*-
4 //
5 // Package: Concurrency
6 // Class : FunctorTask
7 //
15 //
16 // Original Author: Chris Jones
17 // Created: Thu Feb 21 13:46:31 CST 2013
18 // $Id$
19 //
20 
21 // system include files
22 #include <atomic>
23 #include <exception>
24 #include <memory>
25 
26 // user include files
28 
29 // forward declarations
30 
31 namespace edm {
32  template <typename F>
33  class FunctorTask : public TaskBase {
34  public:
35  explicit FunctorTask(F f) : func_(std::move(f)) {}
36 
37  void execute() final { func_(); };
38 
39  private:
40  F func_;
41  };
42 
43  template <typename F>
45  return new FunctorTask<F>(std::move(f));
46  }
47 } // namespace edm
48 
49 #endif
double f[11][100]
void execute() final
Definition: FunctorTask.h:37
FunctorTask< F > * make_functor_task(F f)
Definition: FunctorTask.h:44
HLT enums.
static uInt32 F(BLOWFISH_CTX *ctx, uInt32 x)
Definition: blowfish.cc:163
def move(src, dest)
Definition: eostools.py:511