libMesh
Static Public Member Functions | List of all members
libMesh::Parallel::Utils::Convert< KeyType > Struct Template Reference

A utility to convert a double to some sort of KeyType, for interpreting how histogram bounds relate to KeyType positions. More...

#include <parallel_conversion_utils.h>

Static Public Member Functions

static KeyType to_key_type (const double f)
 

Detailed Description

template<typename KeyType>
struct libMesh::Parallel::Utils::Convert< KeyType >

A utility to convert a double to some sort of KeyType, for interpreting how histogram bounds relate to KeyType positions.

This is a class to allow partial template specialization for the std::pair case without adding a "dummy" variable.

Definition at line 78 of file parallel_conversion_utils.h.

Member Function Documentation

◆ to_key_type()

template<typename KeyType >
static KeyType libMesh::Parallel::Utils::Convert< KeyType >::to_key_type ( const double  f)
inlinestatic

Definition at line 80 of file parallel_conversion_utils.h.

Referenced by libMesh::Parallel::BinSorter< KeyType, IdxType >::binsort(), and libMesh::Parallel::Histogram< KeyType, IdxType >::make_histogram().

81  {
82  return static_cast<KeyType>(f);
83  }

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