|
ACTS
Experiment-independent tracking
|
Common base class for all Axis instance. More...
#include <Acts/Utilities/IAxis.hpp>
Public Member Functions | |
| virtual | ~IAxis ()=default |
| Virtual destructor. | |
| virtual std::vector< double > | getBinEdges () const =0 |
| Return a vector of bin edges. | |
| virtual AxisBoundaryType | getBoundaryType () const =0 |
| returns the boundary type set in the template param | |
| virtual double | getMax () const =0 |
| get maximum of binning range | |
| virtual double | getMin () const =0 |
| get minimum of binning range | |
| virtual std::size_t | getNBins () const =0 |
| get total number of bins | |
| virtual AxisType | getType () const =0 |
| returns the type of the axis | |
| virtual bool | isEquidistant () const =0 |
| returns whether the axis is equidistant | |
| virtual bool | isVariable () const =0 |
| returns whether the axis is variable | |
| template<typename callable_t> | |
| decltype(auto) | visit (const callable_t &callable) const |
Helper function that dispatches from the IAxis base class to a concrete axis type. | |
Static Public Member Functions | |
| static std::unique_ptr< IAxis > | createEquidistant (AxisBoundaryType aBoundaryType, double min, double max, std::size_t nbins) |
| Centralized axis factory for equidistant binning. | |
| static std::unique_ptr< IAxis > | createVariable (AxisBoundaryType aBoundaryType, const std::vector< double > &edges) |
| Centralized axis factory for variable binning. | |
Protected Member Functions | |
| virtual void | toStream (std::ostream &os) const =0 |
| Dispatch to the correct stream operator. | |
Common base class for all Axis instance.
This allows generice handling such as for inspection.
|
virtualdefault |
Virtual destructor.
|
static |
Centralized axis factory for equidistant binning.
| aBoundaryType | the axis boundary type |
| min | the minimum edge of the axis |
| max | the maximum edge of the axis |
| nbins | the number of bins |
| std::invalid_argument | if min >= max or nbins == 0 |
|
static |
Centralized axis factory for variable binning.
| aBoundaryType | the axis boundary type |
| edges | are the bin edges |
| std::invalid_argument | if edges is empty or not strictly increasing |
|
pure virtual |
Return a vector of bin edges.
Implemented in Acts::Axis< AxisType::Equidistant, bdt >, and Acts::Axis< AxisType::Variable, bdt >.
|
pure virtual |
returns the boundary type set in the template param
AxisBoundaryType of this axis Implemented in Acts::Axis< AxisType::Equidistant, bdt >, and Acts::Axis< AxisType::Variable, bdt >.
|
pure virtual |
get maximum of binning range
Implemented in Acts::Axis< AxisType::Equidistant, bdt >, and Acts::Axis< AxisType::Variable, bdt >.
|
pure virtual |
get minimum of binning range
Implemented in Acts::Axis< AxisType::Equidistant, bdt >, and Acts::Axis< AxisType::Variable, bdt >.
|
pure virtual |
get total number of bins
Implemented in Acts::Axis< AxisType::Equidistant, bdt >, and Acts::Axis< AxisType::Variable, bdt >.
|
pure virtual |
returns the type of the axis
AxisType of this axis Implemented in Acts::Axis< AxisType::Equidistant, bdt >, and Acts::Axis< AxisType::Variable, bdt >.
|
pure virtual |
returns whether the axis is equidistant
Implemented in Acts::Axis< AxisType::Equidistant, bdt >, and Acts::Axis< AxisType::Variable, bdt >.
|
pure virtual |
returns whether the axis is variable
Implemented in Acts::Axis< AxisType::Equidistant, bdt >, and Acts::Axis< AxisType::Variable, bdt >.
|
protectedpure virtual |
Dispatch to the correct stream operator.
| os | output stream |
Implemented in Acts::Axis< AxisType::Equidistant, bdt >, and Acts::Axis< AxisType::Variable, bdt >.
| decltype(auto) Acts::IAxis::visit | ( | const callable_t & | callable | ) | const |
Helper function that dispatches from the IAxis base class to a concrete axis type.
It will call the provided callable with a const reference to the concrete axis type.
| callable_t | the callable type |
| callable | the callable object |