CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
RunPrincipal.h
Go to the documentation of this file.
1 #ifndef FWCore_Framework_RunPrincipal_h
2 #define FWCore_Framework_RunPrincipal_h
3 
4 /*----------------------------------------------------------------------
5 
6 RunPrincipal: This is the class responsible for management of
7 per run EDProducts. It is not seen by reconstruction code;
8 such code sees the Run class, which is a proxy for RunPrincipal.
9 
10 The major internal component of the RunPrincipal
11 is the DataBlock.
12 
13 ----------------------------------------------------------------------*/
14 
15 #include <string>
16 #include <vector>
17 
18 #include "boost/shared_ptr.hpp"
19 
22 
23 namespace edm {
24 
25  class HistoryAppender;
26  class UnscheduledHandler;
27 
28  class RunPrincipal : public Principal {
29  public:
31  typedef Principal Base;
32 
34  boost::shared_ptr<RunAuxiliary> aux,
35  boost::shared_ptr<ProductRegistry const> reg,
36  ProcessConfiguration const& pc,
37  HistoryAppender* historyAppender = 0);
39 
41 
42  RunAuxiliary const& aux() const {
43  return *aux_;
44  }
45 
46  RunNumber_t run() const {
47  return aux().run();
48  }
49 
50  RunID const& id() const {
51  return aux().id();
52  }
53 
54  Timestamp const& beginTime() const {
55  return aux().beginTime();
56  }
57 
58  Timestamp const& endTime() const {
59  return aux().endTime();
60  }
61 
62  void setEndTime(Timestamp const& time) {
63  aux_->setEndTime(time);
64  }
65 
67  return aux_->mergeAuxiliary(aux);
68  }
69 
70  void setUnscheduledHandler(boost::shared_ptr<UnscheduledHandler>) {}
71 
72  void put(
73  ConstBranchDescription const& bd,
74  WrapperOwningHolder const& edp);
75 
76  void readImmediate() const;
77 
78  private:
79 
80  virtual bool unscheduledFill(std::string const&) const {return false;}
81 
82  void resolveProductImmediate(Group const& g) const;
83 
84  // A vector of groups.
85  boost::shared_ptr<RunAuxiliary> aux_;
86  };
87 }
88 #endif
89 
void fillRunPrincipal(DelayedReader *reader=0)
Definition: RunPrincipal.cc:21
Timestamp const & endTime() const
Definition: RunAuxiliary.h:40
boost::shared_ptr< RunAuxiliary > aux_
Definition: RunPrincipal.h:85
RunNumber_t run() const
Definition: RunPrincipal.h:46
The Signals That Services Can Subscribe To This is based on ActivityRegistry and is current per Services can connect to the signals distributed by the ActivityRegistry in order to monitor the activity of the application Each possible callback has some defined which we here list in angle e g
Definition: Activities.doc:4
void readImmediate() const
Definition: RunPrincipal.cc:48
void mergeAuxiliary(RunAuxiliary const &aux)
Definition: RunPrincipal.h:66
void setEndTime(Timestamp const &time)
Definition: RunPrincipal.h:62
RunID const & id() const
Definition: RunAuxiliary.h:37
Timestamp const & beginTime() const
Definition: RunAuxiliary.h:39
void put(ConstBranchDescription const &bd, WrapperOwningHolder const &edp)
Definition: RunPrincipal.cc:31
Timestamp const & beginTime() const
Definition: RunPrincipal.h:54
Timestamp const & endTime() const
Definition: RunPrincipal.h:58
RunAuxiliary const & aux() const
Definition: RunPrincipal.h:42
void setUnscheduledHandler(boost::shared_ptr< UnscheduledHandler >)
Definition: RunPrincipal.h:70
RunID const & id() const
Definition: RunPrincipal.h:50
virtual bool unscheduledFill(std::string const &) const
Definition: RunPrincipal.h:80
DelayedReader * reader() const
Definition: Principal.h:149
RunAuxiliary Auxiliary
Definition: RunPrincipal.h:30
unsigned int RunNumber_t
Definition: EventRange.h:32
RunPrincipal(boost::shared_ptr< RunAuxiliary > aux, boost::shared_ptr< ProductRegistry const > reg, ProcessConfiguration const &pc, HistoryAppender *historyAppender=0)
Definition: RunPrincipal.cc:11
void resolveProductImmediate(Group const &g) const
Definition: RunPrincipal.cc:60
RunNumber_t run() const
Definition: RunAuxiliary.h:41