CosmoBolognaLib
Free Software C++/Python libraries for cosmological calculations
EnumCast.h File Reference

Classes used to cast integers and std::string into the enums used in the CosmoBolognaLib. More...

This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Namespaces

 cbl
 The global namespace of the CosmoBolognaLib
 

Functions

template<typename T , typename std::enable_if< std::is_enum< T >::value >::type * = nullptr>
cbl::castFromValue (const int i)
 cast an object of type enum class from its index More...
 
template<typename T , typename std::enable_if< std::is_enum< T >::value >::type * = nullptr>
cbl::castFromName (const std::string name, const std::vector< std::string > list)
 cast an object of type enum class from its name More...
 
template<typename T , typename std::enable_if< std::is_enum< T >::value >::type * = nullptr>
std::vector< T > cbl::castFromValues (const std::vector< int > ii)
 cast objects of type enum class from indeces More...
 
template<typename T , typename std::enable_if< std::is_enum< T >::value >::type * = nullptr>
std::vector< T > cbl::castFromNames (const std::vector< std::string > names, const std::vector< std::string > list)
 cast an object of type enum class from names More...
 

Detailed Description

Classes used to cast integers and std::string into the enums used in the CosmoBolognaLib.

This file contains the function used to cast integers and std::string into the enums used in the CosmoBolognaLib

Author
Federico Marulli
feder.nosp@m.ico..nosp@m.marul.nosp@m.li3@.nosp@m.unibo.nosp@m..it

Definition in file EnumCast.h.