LArSoft  v09_90_00
Liquid Argon Software toolkit - https://larsoft.org/
art::ProductProvenance Class Reference

#include "ProductProvenance.h"

Classes

struct  Transients
 

Public Member Functions

 ~ProductProvenance ()
 
 ProductProvenance ()
 
 ProductProvenance (ProductID const &, ProductStatus)
 
 ProductProvenance (ProductID const &, ProductStatus, std::vector< ProductID > const &parents)
 
 ProductProvenance (ProductProvenance const &)
 
 ProductProvenance (ProductProvenance &&)
 
ProductProvenanceoperator= (ProductProvenance const &)
 
ProductProvenanceoperator= (ProductProvenance &&)
 
void write (std::ostream &) const
 
ProductID productID () const noexcept
 
ProductStatus productStatus () const noexcept
 
ParentageID const & parentageID () const noexcept
 
Parentage const & parentage () const
 
bool noParentage () const noexcept
 

Private Attributes

ProductID productID_ {}
 
ProductStatus productStatus_ {productstatus::uninitialized()}
 
ParentageID parentageID_ {}
 
Transient< Transientstransients_ {}
 

Detailed Description

Definition at line 20 of file ProductProvenance.h.

Constructor & Destructor Documentation

art::ProductProvenance::~ProductProvenance ( )
default
art::ProductProvenance::ProductProvenance ( )
default

Referenced by ProductProvenance().

art::ProductProvenance::ProductProvenance ( ProductID const &  bid,
ProductStatus  status 
)

Definition at line 17 of file ProductProvenance.cc.

References productStatus_.

19  : productID_{bid}, productStatus_{status}
20  {}
ProductStatus productStatus_
art::ProductProvenance::ProductProvenance ( ProductID const &  bid,
ProductStatus  status,
std::vector< ProductID > const &  parents 
)

Definition at line 22 of file ProductProvenance.cc.

References art::thread_safe_registry_via_id< K, M >::emplace(), operator=(), parentageID_, ProductProvenance(), productStatus_, and transients_.

25  : productID_{bid}
26  , productStatus_{status}
27  , transients_{{false, Parentage{parents}}}
28  {
29  parentageID_ = transients_.get().parentage_.id();
31  }
ProductStatus productStatus_
Transient< Transients > transients_
static auto emplace(value_type const &value)
art::ProductProvenance::ProductProvenance ( ProductProvenance const &  )
default
art::ProductProvenance::ProductProvenance ( ProductProvenance &&  )
default

Member Function Documentation

bool art::ProductProvenance::noParentage ( ) const
noexcept

Definition at line 60 of file ProductProvenance.cc.

References transients_.

Referenced by write().

61  {
62  return transients_.get().noParentage_;
63  }
Transient< Transients > transients_
ProductProvenance & art::ProductProvenance::operator= ( ProductProvenance const &  )
default

Referenced by ProductProvenance().

ProductProvenance & art::ProductProvenance::operator= ( ProductProvenance &&  )
default
Parentage const & art::ProductProvenance::parentage ( ) const

Definition at line 66 of file ProductProvenance.cc.

References art::thread_safe_registry_via_id< K, M >::get(), parentageID_, and transients_.

Referenced by art::markAncestors().

67  {
69  return transients_.get().parentage_;
70  }
static collection_type const & get()
Transient< Transients > transients_
ParentageID const & art::ProductProvenance::parentageID ( ) const
noexcept

Definition at line 53 of file ProductProvenance.cc.

References parentageID_.

Referenced by write().

54  {
55  return parentageID_;
56  }
ProductID art::ProductProvenance::productID ( ) const
noexcept

Definition at line 41 of file ProductProvenance.cc.

References productID_.

Referenced by write().

42  {
43  return productID_;
44  }
ProductStatus art::ProductProvenance::productStatus ( ) const
noexcept

Definition at line 47 of file ProductProvenance.cc.

References productStatus_.

48  {
49  return productStatus_;
50  }
ProductStatus productStatus_
void art::ProductProvenance::write ( std::ostream &  os) const

Definition at line 73 of file ProductProvenance.cc.

References noParentage(), parentageID(), productID(), and productStatus_.

Referenced by art::operator<<().

74  {
75  os << "product ID = " << productID() << '\n';
76  os << "product status = " << static_cast<int>(productStatus_) << '\n';
77  if (!noParentage()) {
78  os << "entry description ID = " << parentageID() << '\n';
79  }
80  }
ParentageID const & parentageID() const noexcept
ProductID productID() const noexcept
ProductStatus productStatus_
bool noParentage() const noexcept

Member Data Documentation

ParentageID art::ProductProvenance::parentageID_ {}
private

Definition at line 49 of file ProductProvenance.h.

Referenced by parentage(), parentageID(), and ProductProvenance().

ProductID art::ProductProvenance::productID_ {}
private

Definition at line 47 of file ProductProvenance.h.

Referenced by productID().

ProductStatus art::ProductProvenance::productStatus_ {productstatus::uninitialized()}
private

Definition at line 48 of file ProductProvenance.h.

Referenced by ProductProvenance(), productStatus(), and write().

Transient<Transients> art::ProductProvenance::transients_ {}
mutableprivate

Definition at line 50 of file ProductProvenance.h.

Referenced by noParentage(), parentage(), and ProductProvenance().


The documentation for this class was generated from the following files: