40 static constexpr CoordT twoEps = 2 * std::numeric_limits<float>::epsilon();
41 if (std::fabs(min) > twoEps)
42 min *= (1 - std::copysign(twoEps, min));
45 if (std::fabs(max) > twoEps)
46 max *= (1 + std::copysign(twoEps, max));
52 void setName(
const std::string &name);
53 void setId(std::string
id);
55 void setMin(
double min);
56 void setMax(
double max);
57 void setNumBins(
size_t nbins);
58 void setFrameName(std::string frameName);
MDHistoDimensionBuilder :
bool m_maxSet
Flag indicating that max has been set.
bool m_minSet
Flag indicating that min has been set.
std::string m_name
Cached name.
std::string m_id
Cached id.
size_t m_nbins
Cached nbins.
size_t getNumBins() const
static void resizeToFitMDBox(CoordT &min, CoordT &max)
Push the min/max values out by a defined amount.
std::string m_frameName
Frame name.
Kernel::UnitLabel m_units
Cached units.
A base-class for the a class that is able to return unit labels in different representations.
std::unique_ptr< T > create(const P &parent, const IndexArg &indexArg, const HistArg &histArg)
This is the create() method that all the other create() methods call.
std::vector< MDHistoDimensionBuilder > Vec_MDHistoDimensionBuilder
Handy typedef for collection of builders.
std::shared_ptr< IMDDimension > IMDDimension_sptr
Shared Pointer for IMDDimension. Frequently used type in framework.
Helper class which provides the Collimation Length for SANS instruments.