LArSoft  v09_90_00
Liquid Argon Software toolkit - https://larsoft.org/
ProductProvenance.h
Go to the documentation of this file.
1 #ifndef canvas_Persistency_Provenance_ProductProvenance_h
2 #define canvas_Persistency_Provenance_ProductProvenance_h
3 // vim: set sw=2 expandtab :
4 
5 // The event dependent portion of the description of a product
6 // and how it came into existence, plus the status.
7 
14 
15 #include <iosfwd>
16 #include <memory>
17 #include <vector>
18 
19 namespace art {
21  public:
22  struct Transients {
23  bool noParentage_{true};
25  };
26 
32  std::vector<ProductID> const& parents);
37 
38  void write(std::ostream&) const;
39  ProductID productID() const noexcept;
40  ProductStatus productStatus() const noexcept;
41  ParentageID const& parentageID() const noexcept;
42  Parentage const& parentage() const;
43  // Note: This is true for Run, SubRun, and Results products.
44  bool noParentage() const noexcept;
45 
46  private:
51  };
52 
53  using ProductProvenances = std::vector<ProductProvenance>;
54 
55  std::ostream& operator<<(std::ostream& os, ProductProvenance const& p);
56  bool operator==(ProductProvenance const& a,
57  ProductProvenance const& b) noexcept;
58  bool operator!=(ProductProvenance const& a,
59  ProductProvenance const& b) noexcept;
60  bool operator<(ProductProvenance const& a,
61  ProductProvenance const& b) noexcept;
62 
63 } // namespace art
64 
65 #endif /* canvas_Persistency_Provenance_ProductProvenance_h */
66 
67 // Local Variables:
68 // mode: c++
69 // End:
bool operator==(Provenance const &a, Provenance const &b) noexcept
Definition: Provenance.cc:141
bool operator!=(ScheduleID const left, ScheduleID const right) noexcept
Definition: ScheduleID.cc:41
ParentageID const & parentageID() const noexcept
ProductID productID() const noexcept
std::ostream & operator<<(std::ostream &os, const GroupSelector &gs)
bool operator<(ProductInfo const &a, ProductInfo const &b)
Definition: ProductInfo.cc:51
constexpr ProductStatus uninitialized() noexcept
Definition: ProductStatus.h:36
std::vector< ProductProvenance > ProductProvenances
Parentage const & parentage() const
ProductStatus productStatus_
bool noParentage() const noexcept
Transient< Transients > transients_
unsigned char ProductStatus
Definition: ProductStatus.h:6
ProductStatus productStatus() const noexcept
ProductProvenance & operator=(ProductProvenance const &)
void write(std::ostream &) const
Definition: MVAAlg.h:12