Nektar++
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
Static Public Member Functions | List of all members
Nektar::ArrayInitializationPolicy< ObjectType, typename boost::enable_if< boost::is_fundamental< ObjectType > >::type > Class Template Reference

#include <ArrayPolicies.hpp>

Static Public Member Functions

static void Initialize (ObjectType *data, unsigned int itemsToCreate)
 
static void Initialize (ObjectType *data, unsigned int itemsToCreate, const ObjectType &initValue)
 
static void Initialize (ObjectType *data, unsigned int itemsToCreate, const ObjectType *initValue)
 

Detailed Description

template<typename ObjectType>
class Nektar::ArrayInitializationPolicy< ObjectType, typename boost::enable_if< boost::is_fundamental< ObjectType > >::type >

Definition at line 54 of file ArrayPolicies.hpp.

Member Function Documentation

template<typename ObjectType >
static void Nektar::ArrayInitializationPolicy< ObjectType, typename boost::enable_if< boost::is_fundamental< ObjectType > >::type >::Initialize ( ObjectType *  data,
unsigned int  itemsToCreate 
)
inlinestatic

Definition at line 58 of file ArrayPolicies.hpp.

59  {
60  }
template<typename ObjectType >
static void Nektar::ArrayInitializationPolicy< ObjectType, typename boost::enable_if< boost::is_fundamental< ObjectType > >::type >::Initialize ( ObjectType *  data,
unsigned int  itemsToCreate,
const ObjectType &  initValue 
)
inlinestatic

Definition at line 62 of file ArrayPolicies.hpp.

63  {
64  std::fill_n(data, itemsToCreate, initValue);
65  }
template<typename ObjectType >
static void Nektar::ArrayInitializationPolicy< ObjectType, typename boost::enable_if< boost::is_fundamental< ObjectType > >::type >::Initialize ( ObjectType *  data,
unsigned int  itemsToCreate,
const ObjectType *  initValue 
)
inlinestatic

Definition at line 67 of file ArrayPolicies.hpp.

68  {
69  std::copy(initValue, initValue + itemsToCreate, data);
70  }