Project
Loading...
Searching...
No Matches
o2::data_compression::ContiguousAlphabet< T, _min, _max, NameT > Class Template Reference

#include <dc_primitives.h>

Inherited by o2::data_compression::ZeroBoundContiguousAlphabet< T, getmax< T, _nbits >::value, boost::mpl::string< 'U', 'n', 'n', 'a', 'm', 'e', 'd'>::type >, and o2::data_compression::ZeroBoundContiguousAlphabet< T, _max, NameT >.

Classes

class  Iterator
 a forward iterator to access the list of elements More...
 

Public Types

using value_type = T
 
using size_type = T
 
using range = boost::mpl::range_c< T, _min, _max >
 
using size = boost::mpl::plus< boost::mpl::size< range >, boost::mpl::int_< 1 > >
 
using iterator = Iterator< value_type >
 
using const_iterator = Iterator< const value_type >
 

Public Member Functions

 ContiguousAlphabet ()=default
 
 ~ContiguousAlphabet ()=default
 
constexpr unsigned getIndexRange ()
 get the range of indices aka number of indices
 
constexpr const chargetName () const
 
const_iterator begin () const
 return forward iterator to begin of element list
 
const_iterator end () const
 the end of element list
 
iterator begin ()
 return forward iterator to begin of element list
 
iterator end ()
 the end of element list
 

Static Public Member Functions

static bool isValid (value_type v)
 check for valid value within range
 
static unsigned getIndex (value_type symbol)
 
static value_type getSymbol (unsigned index)
 get symbol from index
 

Detailed Description

template<typename T, T _min, T _max, typename NameT = boost::mpl::string<'U', 'n', 'n', 'a', 'm', 'e', 'd'>::type>
class o2::data_compression::ContiguousAlphabet< T, _min, _max, NameT >

Definition at line 208 of file dc_primitives.h.

Member Typedef Documentation

◆ const_iterator

template<typename T , T _min, T _max, typename NameT = boost::mpl::string<'U', 'n', 'n', 'a', 'm', 'e', 'd'>::type>
using o2::data_compression::ContiguousAlphabet< T, _min, _max, NameT >::const_iterator = Iterator<const value_type>

Definition at line 312 of file dc_primitives.h.

◆ iterator

template<typename T , T _min, T _max, typename NameT = boost::mpl::string<'U', 'n', 'n', 'a', 'm', 'e', 'd'>::type>
using o2::data_compression::ContiguousAlphabet< T, _min, _max, NameT >::iterator = Iterator<value_type>

Definition at line 311 of file dc_primitives.h.

◆ range

template<typename T , T _min, T _max, typename NameT = boost::mpl::string<'U', 'n', 'n', 'a', 'm', 'e', 'd'>::type>
using o2::data_compression::ContiguousAlphabet< T, _min, _max, NameT >::range = boost::mpl::range_c<T, _min, _max>

Definition at line 216 of file dc_primitives.h.

◆ size

template<typename T , T _min, T _max, typename NameT = boost::mpl::string<'U', 'n', 'n', 'a', 'm', 'e', 'd'>::type>
using o2::data_compression::ContiguousAlphabet< T, _min, _max, NameT >::size = boost::mpl::plus<boost::mpl::size<range>, boost::mpl::int_<1> >

Definition at line 217 of file dc_primitives.h.

◆ size_type

template<typename T , T _min, T _max, typename NameT = boost::mpl::string<'U', 'n', 'n', 'a', 'm', 'e', 'd'>::type>
using o2::data_compression::ContiguousAlphabet< T, _min, _max, NameT >::size_type = T

Definition at line 215 of file dc_primitives.h.

◆ value_type

template<typename T , T _min, T _max, typename NameT = boost::mpl::string<'U', 'n', 'n', 'a', 'm', 'e', 'd'>::type>
using o2::data_compression::ContiguousAlphabet< T, _min, _max, NameT >::value_type = T

Definition at line 214 of file dc_primitives.h.

Constructor & Destructor Documentation

◆ ContiguousAlphabet()

template<typename T , T _min, T _max, typename NameT = boost::mpl::string<'U', 'n', 'n', 'a', 'm', 'e', 'd'>::type>
o2::data_compression::ContiguousAlphabet< T, _min, _max, NameT >::ContiguousAlphabet ( )
default

◆ ~ContiguousAlphabet()

template<typename T , T _min, T _max, typename NameT = boost::mpl::string<'U', 'n', 'n', 'a', 'm', 'e', 'd'>::type>
o2::data_compression::ContiguousAlphabet< T, _min, _max, NameT >::~ContiguousAlphabet ( )
default

Member Function Documentation

◆ begin() [1/2]

template<typename T , T _min, T _max, typename NameT = boost::mpl::string<'U', 'n', 'n', 'a', 'm', 'e', 'd'>::type>
iterator o2::data_compression::ContiguousAlphabet< T, _min, _max, NameT >::begin ( )
inline

return forward iterator to begin of element list

Definition at line 321 of file dc_primitives.h.

◆ begin() [2/2]

template<typename T , T _min, T _max, typename NameT = boost::mpl::string<'U', 'n', 'n', 'a', 'm', 'e', 'd'>::type>
const_iterator o2::data_compression::ContiguousAlphabet< T, _min, _max, NameT >::begin ( ) const
inline

return forward iterator to begin of element list

Definition at line 315 of file dc_primitives.h.

◆ end() [1/2]

template<typename T , T _min, T _max, typename NameT = boost::mpl::string<'U', 'n', 'n', 'a', 'm', 'e', 'd'>::type>
iterator o2::data_compression::ContiguousAlphabet< T, _min, _max, NameT >::end ( )
inline

the end of element list

Definition at line 324 of file dc_primitives.h.

◆ end() [2/2]

template<typename T , T _min, T _max, typename NameT = boost::mpl::string<'U', 'n', 'n', 'a', 'm', 'e', 'd'>::type>
const_iterator o2::data_compression::ContiguousAlphabet< T, _min, _max, NameT >::end ( ) const
inline

the end of element list

Definition at line 318 of file dc_primitives.h.

◆ getIndex()

template<typename T , T _min, T _max, typename NameT = boost::mpl::string<'U', 'n', 'n', 'a', 'm', 'e', 'd'>::type>
static unsigned o2::data_compression::ContiguousAlphabet< T, _min, _max, NameT >::getIndex ( value_type  symbol)
inlinestatic

get index of symbol

Each alphabet has to provide a one to one mapping of symbols to index values used for internal storage For performance reasons, there is no range check

Definition at line 227 of file dc_primitives.h.

◆ getIndexRange()

template<typename T , T _min, T _max, typename NameT = boost::mpl::string<'U', 'n', 'n', 'a', 'm', 'e', 'd'>::type>
constexpr unsigned o2::data_compression::ContiguousAlphabet< T, _min, _max, NameT >::getIndexRange ( )
inlineconstexpr

get the range of indices aka number of indices

Definition at line 242 of file dc_primitives.h.

◆ getName()

template<typename T , T _min, T _max, typename NameT = boost::mpl::string<'U', 'n', 'n', 'a', 'm', 'e', 'd'>::type>
constexpr const char * o2::data_compression::ContiguousAlphabet< T, _min, _max, NameT >::getName ( ) const
inlineconstexpr

get the name of the alphabet

name is part of the type definition, defined as a boost mpl string

Definition at line 247 of file dc_primitives.h.

◆ getSymbol()

template<typename T , T _min, T _max, typename NameT = boost::mpl::string<'U', 'n', 'n', 'a', 'm', 'e', 'd'>::type>
static value_type o2::data_compression::ContiguousAlphabet< T, _min, _max, NameT >::getSymbol ( unsigned  index)
inlinestatic

get symbol from index

Definition at line 239 of file dc_primitives.h.

◆ isValid()

template<typename T , T _min, T _max, typename NameT = boost::mpl::string<'U', 'n', 'n', 'a', 'm', 'e', 'd'>::type>
static bool o2::data_compression::ContiguousAlphabet< T, _min, _max, NameT >::isValid ( value_type  v)
inlinestatic

check for valid value within range

Definition at line 220 of file dc_primitives.h.


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