ProductStatus.h
Go to the documentation of this file.
1 #ifndef canvas_Persistency_Provenance_ProductStatus_h
2 #define canvas_Persistency_Provenance_ProductStatus_h
3 
4 namespace art {
5 
6  using ProductStatus = unsigned char;
7 
8  namespace productstatus {
9  constexpr ProductStatus
10  present() noexcept
11  {
12  return 0x0;
13  } // Product was made successfully
14  constexpr ProductStatus
15  neverCreated() noexcept
16  {
17  return 0x1;
18  } // Product was not made successfully
19  constexpr ProductStatus
20  dropped() noexcept
21  {
22  return 0x2;
23  } // Product was not made successfully
24  constexpr ProductStatus
26  {
27  return 0x3;
28  } // Product is a dummy placeholder object with an invalid range set to
29  // prevent double-counting when combining run/subrun products
30  constexpr ProductStatus
31  unknown() noexcept
32  {
33  return 0xfe;
34  } // Status unknown (used for backward compatibility)
35  constexpr ProductStatus
36  uninitialized() noexcept
37  {
38  return 0xff;
39  } // Status not set
40 
41  constexpr bool
42  present(ProductStatus const status) noexcept
43  {
44  return status == present();
45  }
46  constexpr bool
48  {
49  return status == neverCreated();
50  }
51  constexpr bool
52  dropped(ProductStatus const status) noexcept
53  {
54  return status == dropped();
55  }
56  constexpr bool
58  {
60  }
61  constexpr bool
62  unknown(ProductStatus const status) noexcept
63  {
64  return status == unknown();
65  }
66  constexpr bool
68  {
69  return status == uninitialized();
70  }
71  } // productstatus
72 } // art
73 
74 #endif /* canvas_Persistency_Provenance_ProductStatus_h */
75 
76 // Local Variables:
77 // mode: c++
78 // End:
int status
Definition: fabricate.py:1613
constexpr ProductStatus dummyToPreventDoubleCount() noexcept
Definition: ProductStatus.h:25
constexpr ProductStatus dropped() noexcept
Definition: ProductStatus.h:20
constexpr ProductStatus uninitialized() noexcept
Definition: ProductStatus.h:36
constexpr ProductStatus unknown() noexcept
Definition: ProductStatus.h:31
unsigned char ProductStatus
Definition: ProductStatus.h:6
constexpr ProductStatus neverCreated() noexcept
Definition: ProductStatus.h:15
Service to store calibration data products (CDP) in the SQLite3 metadatabase of a file...
Definition: FillParentInfo.h:8
constexpr ProductStatus present() noexcept
Definition: ProductStatus.h:10