Fast Methods for Cosmological Simulations
FastSim serves as a tool for quick N-body simulations in modified gravity.
Catch::Generators::RangeGenerator< T > Class Template Reference

#include <catch.hpp>

Inheritance diagram for Catch::Generators::RangeGenerator< T >:
Collaboration diagram for Catch::Generators::RangeGenerator< T >:

Public Member Functions

 RangeGenerator (T const &first, T const &last)
 
auto get (size_t index) const -> T override
 
- Public Member Functions inherited from Catch::Generators::IGenerator< T >
virtual ~IGenerator ()
 

Private Attributes

T const m_first
 
T const m_last
 

Detailed Description

template<typename T>
class Catch::Generators::RangeGenerator< T >

Definition at line 3088 of file catch.hpp.

Constructor & Destructor Documentation

template<typename T >
Catch::Generators::RangeGenerator< T >::RangeGenerator ( T const &  first,
T const &  last 
)
inline

Definition at line 3093 of file catch.hpp.

3093  : m_first( first ), m_last( last ) {
3094  assert( m_last > m_first );
3095  }

Member Function Documentation

template<typename T >
auto Catch::Generators::RangeGenerator< T >::get ( size_t  index) const -> T
inlineoverridevirtual

Implements Catch::Generators::IGenerator< T >.

Definition at line 3097 of file catch.hpp.

References growth_allz::T.

3097  {
3098  // ToDo:: introduce a safe cast to catch potential overflows
3099  return static_cast<T>(m_first+index);
3100  }

Member Data Documentation

template<typename T >
T const Catch::Generators::RangeGenerator< T >::m_first
private

Definition at line 3089 of file catch.hpp.

template<typename T >
T const Catch::Generators::RangeGenerator< T >::m_last
private

Definition at line 3090 of file catch.hpp.


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