Logo ROOT  
Reference Guide
 
Loading...
Searching...
No Matches
ROOT::Experimental::RAxisVariant Class Referencefinal

A variant of all supported axis types.

This class provides easy access to the contained axis object and dispatching methods for common accessors.

Warning
This is part of the ROOT 7 prototype! It will change without notice. It might trigger earthquakes. Feedback is welcome!

Definition at line 30 of file RAxisVariant.hxx.

Public Types

using VariantType = std::variant<RRegularAxis, RVariableBinAxis, RCategoricalAxis>
 

Public Member Functions

 RAxisVariant (RCategoricalAxis axis)
 
 RAxisVariant (RRegularAxis axis)
 
 RAxisVariant (RVariableBinAxis axis)
 
 RAxisVariant (VariantType axis)
 
const RCategoricalAxisGetCategoricalAxis () const
 
RBinIndexRange GetFullRange () const
 Get the full range of all bins.
 
std::uint64_t GetNNormalBins () const
 
RBinIndexRange GetNormalRange () const
 Get the range of all normal bins.
 
RBinIndexRange GetNormalRange (RBinIndex begin, RBinIndex end) const
 Get a range of normal bins.
 
const RRegularAxisGetRegularAxis () const
 
std::uint64_t GetTotalNBins () const
 
const RVariableBinAxisGetVariableBinAxis () const
 
const VariantTypeGetVariant () const
 
void Streamer (TBuffer &)
 ROOT Streamer function to throw when trying to store an object of this class.
 

Private Attributes

VariantType fVariant
 

Friends

bool operator== (const RAxisVariant &lhs, const RAxisVariant &rhs)
 

#include <ROOT/RAxisVariant.hxx>

Member Typedef Documentation

◆ VariantType

Constructor & Destructor Documentation

◆ RAxisVariant() [1/4]

ROOT::Experimental::RAxisVariant::RAxisVariant ( VariantType axis)
inline

Definition at line 38 of file RAxisVariant.hxx.

◆ RAxisVariant() [2/4]

ROOT::Experimental::RAxisVariant::RAxisVariant ( RRegularAxis axis)
inline

Definition at line 39 of file RAxisVariant.hxx.

◆ RAxisVariant() [3/4]

ROOT::Experimental::RAxisVariant::RAxisVariant ( RVariableBinAxis axis)
inline

Definition at line 40 of file RAxisVariant.hxx.

◆ RAxisVariant() [4/4]

ROOT::Experimental::RAxisVariant::RAxisVariant ( RCategoricalAxis axis)
inline

Definition at line 41 of file RAxisVariant.hxx.

Member Function Documentation

◆ GetCategoricalAxis()

const RCategoricalAxis * ROOT::Experimental::RAxisVariant::GetCategoricalAxis ( ) const
inline
Returns
the RCategoricalAxis or nullptr, if this variant stores a different axis type

Definition at line 50 of file RAxisVariant.hxx.

◆ GetFullRange()

RBinIndexRange ROOT::Experimental::RAxisVariant::GetFullRange ( ) const
inline

Get the full range of all bins.

This includes underflow and overflow bins, if enabled.

Returns
the bin index range of all bins

Definition at line 117 of file RAxisVariant.hxx.

◆ GetNNormalBins()

std::uint64_t ROOT::Experimental::RAxisVariant::GetNNormalBins ( ) const
inline

Definition at line 52 of file RAxisVariant.hxx.

◆ GetNormalRange() [1/2]

RBinIndexRange ROOT::Experimental::RAxisVariant::GetNormalRange ( ) const
inline

Get the range of all normal bins.

Returns
the bin index range from the first to the last normal bin, inclusive

Definition at line 81 of file RAxisVariant.hxx.

◆ GetNormalRange() [2/2]

RBinIndexRange ROOT::Experimental::RAxisVariant::GetNormalRange ( RBinIndex begin,
RBinIndex end ) const
inline

Get a range of normal bins.

Parameters
[in]beginthe begin of the bin index range (inclusive), must be normal
[in]endthe end of the bin index range (exclusive), must be normal and >= begin
Returns
a bin index range \([begin, end)\)

Definition at line 99 of file RAxisVariant.hxx.

◆ GetRegularAxis()

const RRegularAxis * ROOT::Experimental::RAxisVariant::GetRegularAxis ( ) const
inline
Returns
the RRegularAxis or nullptr, if this variant stores a different axis type

Definition at line 46 of file RAxisVariant.hxx.

◆ GetTotalNBins()

std::uint64_t ROOT::Experimental::RAxisVariant::GetTotalNBins ( ) const
inline

Definition at line 65 of file RAxisVariant.hxx.

◆ GetVariableBinAxis()

const RVariableBinAxis * ROOT::Experimental::RAxisVariant::GetVariableBinAxis ( ) const
inline
Returns
the RVariableBinAxis or nullptr, if this variant stores a different axis type

Definition at line 48 of file RAxisVariant.hxx.

◆ GetVariant()

const VariantType & ROOT::Experimental::RAxisVariant::GetVariant ( ) const
inline

Definition at line 43 of file RAxisVariant.hxx.

◆ Streamer()

void ROOT::Experimental::RAxisVariant::Streamer ( TBuffer & )
inline

ROOT Streamer function to throw when trying to store an object of this class.

Definition at line 133 of file RAxisVariant.hxx.

Friends And Related Symbol Documentation

◆ operator==

bool operator== ( const RAxisVariant & lhs,
const RAxisVariant & rhs )
friend

Definition at line 130 of file RAxisVariant.hxx.

Member Data Documentation

◆ fVariant

VariantType ROOT::Experimental::RAxisVariant::fVariant
private

Definition at line 35 of file RAxisVariant.hxx.

Libraries for ROOT::Experimental::RAxisVariant:

The documentation for this class was generated from the following file: