OpenFPM_pdata  4.1.0
Project that contain the implementation of distributed structures
 
Loading...
Searching...
No Matches
v_transform_two< H, arg0, L > Struct Template Reference

Detailed Description

template<template< typename, typename > class H, typename arg0, typename L>
struct v_transform_two< H, arg0, L >

It transform a boost::fusion::vector to another boost::fusion::vector applying a meta-function H on each element

Parameters
H2-argument metafunction (is a structure with typedef type)
Lboost::fusion::vector

Meta-function definition

template <typename arg0, typename T>
struct Ftwo
{
typedef aggregate<T> type;
};
[v_transform metafunction]
aggregate of properties, from a list of object if create a struct that follow the OPENFPM native stru...
v_transform_two_impl< H, arg0, first, last, exit_::value >::type type
generate the boost::fusion::vector apply H on each term

Usage

typedef boost::mpl::vector<float,float,float[3]> bfv;
// tbvf is boost::fusion::vector<scalar<float>,scalar<float>,scalar<float[3]>>
bool val = std::is_same<boost::mpl::at<tbfv,boost::mpl::int_<0>>::type,aggregate<float>>::value;
BOOST_REQUIRE_EQUAL(val,true);
val = std::is_same<boost::mpl::at<tbfv,boost::mpl::int_<1>>::type,aggregate<float>>::value;
BOOST_REQUIRE_EQUAL(val,true);
val = std::is_same<boost::mpl::at<tbfv,boost::mpl::int_<2>>::type,aggregate<float[3]>>::value;
BOOST_REQUIRE_EQUAL(val,true);

Definition at line 178 of file variadic_to_vmpl.hpp.

#include <variadic_to_vmpl.hpp>

Public Types

typedef boost::mpl::reverse< L >::type reversed_
 reverse the sequence
 
typedef seq_traits_impl< reversed_ >::first_ first
 first element
 
typedef seq_traits_impl< reversed_ >::last_ last
 last element
 
typedef exit_impl< first, last >::type exit_
 calculate the exit condition
 
typedef v_transform_two_impl< H, arg0, first, last, exit_::value >::type type
 generate the boost::fusion::vector apply H on each term
 

Member Typedef Documentation

◆ exit_

template<template< typename, typename > class H, typename arg0 , typename L >
typedef exit_impl<first,last>::type v_transform_two< H, arg0, L >::exit_

calculate the exit condition

Definition at line 190 of file variadic_to_vmpl.hpp.

◆ first

template<template< typename, typename > class H, typename arg0 , typename L >
typedef seq_traits_impl<reversed_>::first_ v_transform_two< H, arg0, L >::first

first element

Definition at line 184 of file variadic_to_vmpl.hpp.

◆ last

template<template< typename, typename > class H, typename arg0 , typename L >
typedef seq_traits_impl<reversed_>::last_ v_transform_two< H, arg0, L >::last

last element

Definition at line 187 of file variadic_to_vmpl.hpp.

◆ reversed_

template<template< typename, typename > class H, typename arg0 , typename L >
typedef boost::mpl::reverse<L>::type v_transform_two< H, arg0, L >::reversed_

reverse the sequence

Definition at line 181 of file variadic_to_vmpl.hpp.

◆ type

template<template< typename, typename > class H, typename arg0 , typename L >
typedef v_transform_two_impl<H,arg0,first,last,exit_::value>::type v_transform_two< H, arg0, L >::type

generate the boost::fusion::vector apply H on each term

Definition at line 193 of file variadic_to_vmpl.hpp.


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