|
| 1 | +/*************************************************************************** |
| 2 | +* Copyright (c) 2017, Johan Mabille, Sylvain Corlay, Wolf Vollprecht and * |
| 3 | +* Martin Renou * |
| 4 | +* * |
| 5 | +* Distributed under the terms of the BSD 3-Clause License. * |
| 6 | +* * |
| 7 | +* The full license is in the file LICENSE, distributed with this software. * |
| 8 | +****************************************************************************/ |
| 9 | + |
| 10 | +#ifndef XFRAME_XVARIABLE_VARIANT_HPP |
| 11 | +#define XFRAME_XVARIABLE_VARIANT_HPP |
| 12 | + |
| 13 | +#include "xvariable.hpp" |
| 14 | + |
| 15 | +namespace xf |
| 16 | +{ |
| 17 | + |
| 18 | + |
| 19 | + template <class... V> |
| 20 | + class xvariable_variant |
| 21 | + { |
| 22 | + }; |
| 23 | + |
| 24 | + // vtype1 = variable<double, coord_type1>; |
| 25 | + // vtype2 variable<int, coord_type2>; |
| 26 | + // vtype1 v1; |
| 27 | + // vtype2 v2; |
| 28 | + |
| 29 | + // auto fr = ("n1", v1) | ("n2", v2); |
| 30 | + // ftype = xframe<L, vtype1, vtype2>; |
| 31 | + // ftype::vtype = variant<variable<double, coord_type1>&, variable<int, coord_type2>&> |
| 32 | + // ftype::vtype::value_type = variant<vtype1::value_type, vtype1::value_type>; |
| 33 | + // ftype::vtype::coordinate_type = variant<vtype1::coordinate_type, vtype2::coordinate_type>; |
| 34 | + // ftype::vtype::dimension_type = variant<vtype1::dimension_type, vtype2::dimension_type>; |
| 35 | + // ftype::vtype::data_type = variant<vtype1::data_type, vtype2::deta_type> |
| 36 | + // ftype::ctype = xcommon_coordinate_type<coord_type1, coord_type2>; |
| 37 | + // ftype::dtype = xcommon_dimension_type<typename vtype1::dimension_type, typename vtype2::dimension_type>; |
| 38 | + // |
| 39 | + // xframe not aligned: |
| 40 | + // std::map<L, ftype::vtype>; |
| 41 | + // ftype::ctype m_coord; |
| 42 | + // ftype::dtype m_dims; |
| 43 | + // f["n1"] returns ?? |
| 44 | + // |
| 45 | + // xframe aligned |
| 46 | + // std::map<L, ftype::vtype::data_type>; |
| 47 | + // ftype::ctype m_coord; |
| 48 | + // ftype::dtype m_dims; |
| 49 | + // f["n1"] |
| 50 | +} |
| 51 | + |
| 52 | +#endif |
| 53 | + |
0 commit comments