31#ifndef G4HnInformation_h
32#define G4HnInformation_h 1
110 : fName(
std::move(name))
111 { fHnDimensionInformations.reserve(nofDimensions); }
139 std::vector<G4HnDimensionInformation> fHnDimensionInformations;
140 std::vector<G4bool> fIsLogAxis {
false,
false,
false };
141 G4bool fActivation {
true };
143 G4bool fPlotting {
false };
161template <
unsigned int DIM>
163 const std::array<G4HnDimension, DIM>& bins,
164 const std::array<G4HnDimensionInformation, DIM>& hnInfo,
165 G4bool isProfile =
false);
172{ fHnDimensionInformations.push_back(hnDimensionInformation); }
178 (*info) = hnDimensionInformation;
182{ fIsLogAxis[axis] = isLog; }
185{ fActivation = activation; }
191{ fPlotting = plotting; }
194{ fFileName = fileName; }
200{
return &(fHnDimensionInformations[dimension]); }
203{
return fHnDimensionInformations[dimension]; }
206{
return fIsLogAxis[axis]; }
209{
return fActivation; }
220template <
unsigned int DIM>
222 const std::array<G4HnDimension, DIM>& bins,
223 const std::array<G4HnDimensionInformation, DIM>& hnInfo,
230 auto dimToCheck = (isProfile) ? DIM -1 : DIM ;
231 for (
unsigned int idim = 0; idim < dimToCheck; ++idim) {
237 result &=
CheckMinMax(bins[DIM-1].fMinValue, bins[DIM-1].fMaxValue);
G4double(*)(G4double) G4Fcn
G4bool CheckDimension(unsigned int idim, const G4HnDimension &dimension, const G4HnDimensionInformation &info)
void UpdateTitle(G4String &title, const G4HnDimensionInformation &hnInfo)
void Update(G4double &value, const G4HnDimensionInformation &hnInfo)
void UpdateValues(G4HnDimension &bins, const G4HnDimensionInformation &hnInfo)
G4bool CheckDimensions(const std::array< G4HnDimension, DIM > &bins, const std::array< G4HnDimensionInformation, DIM > &hnInfo, G4bool isProfile=false)
G4bool CheckMinMax(G4double min, G4double max)
G4HnDimension & operator=(const G4HnDimension &rhs)=default
G4HnDimension(G4int nbins, G4double minValue, G4double maxValue)
std::vector< G4double > fEdges
G4HnDimension(const std::vector< G4double > &edges)
G4HnDimension(const G4HnDimension &rhs)=default