10 #ifndef LARDATAOBJ_RECOBASE_CHARGE_H
11 #define LARDATAOBJ_RECOBASE_CHARGE_H
39 = std::numeric_limits<Charge_t>::lowest();
106 template <
typename Stream>
108 Stream&& out,
unsigned int verbosity,
109 std::string indent, std::string firstIndent
113 template <
typename Stream>
115 (
Stream&& out,
unsigned int verbosity, std::string indent =
"")
const
116 {
dump(std::forward<Stream>(out), verbosity, indent, indent); }
117 template <
typename Stream>
118 void dump(
Stream&& out, std::string indent, std::string firstIndent)
const
120 template <
typename Stream>
122 {
dump(std::forward<Stream>(out), indent, indent); }
134 inline std::ostream&
operator<<
136 { charge.dump(out);
return out; }
146 template <
typename Stream>
148 Stream&& out,
unsigned int verbosity,
149 std::string indent, std::string firstIndent
152 if (verbosity <= 0U)
return;
164 static_assert(
MaxVerbosity == 1U,
"Please update the code!");
171 #endif // LARDATAOBJ_RECOBASE_CHARGE_H
constexpr PointCharge(Charge_t charge)
Constructor: sets all the data.
static constexpr Charge_t InvalidCharge
Value used for default-constructed ("invalid") charge.
void dump(Stream &&out, unsigned int verbosity, std::string indent, std::string firstIndent) const
Dump the content of this object into an output stream.
void dump(Stream &&out, std::string indent="") const
constexpr PointCharge()
Default constructor (for ROOT only).
constexpr bool hasCharge() const
Returns whether the reconstructed charge value is valid.
static constexpr unsigned int DefaultVerbosity
Default verbosity for dumping operations.
float fCharge
Reconstructed charge.
static constexpr unsigned int MaxVerbosity
Maximum available verbosity for dumping operations.
float Charge_t
Type for the amount of reconstructed charge.
void dump(Stream &&out, std::string indent, std::string firstIndent) const
constexpr Charge_t charge() const
Returns the stored value of the reconstructed charge.
Charge reconstructed in the active volume.