Changeset 352 for XIOS/trunk/src/array.hpp
- Timestamp:
- 07/09/12 11:33:05 (12 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
XIOS/trunk/src/array.hpp
r335 r352 16 16 { 17 17 template<size_t numDims> 18 detail::multi_array::extent_gen<numDims> getExtentNull(void) { return getExtentNull<numDims-1>()[0];}18 inline detail::multi_array::extent_gen<numDims> getExtentNull(void) { return getExtentNull<numDims-1>()[0];} 19 19 20 20 template<> 21 detail::multi_array::extent_gen<1> getExtentNull<1>(void) { return extents[0]; }21 inline detail::multi_array::extent_gen<1> getExtentNull<1>(void) { return extents[0]; } 22 22 23 23 /// ////////////////////// Déclarations ////////////////////// /// 24 template <typename ValueType, StdSize NumDims, 25 typename Allocator = std::allocator<ValueType> > 26 class CArray 27 : public boost::multi_array<ValueType, NumDims, Allocator> 24 25 template <typename ValueType, StdSize NumDims, typename Allocator = std::allocator<ValueType> > 26 class CArray : public boost::multi_array<ValueType, NumDims, Allocator> 28 27 { 29 28 /// Définition de type /// … … 35 34 36 35 /// Constructeurs /// 37 template <typename ExtentList> 38 explicit CArray(const ExtentList & sizes); 36 // template <typename ExtentList> 37 // explicit CArray(const ExtentList & sizes); 38 template <typename ExtentList> CArray(const ExtentList & sizes) 39 : boost::multi_array<ValueType, NumDims, Allocator> 40 (sizes, boost::fortran_storage_order()) 41 { /* Ne rien faire de plus */ } 42 39 43 40 44 explicit CArray(); 41 45 42 template <typename ExtentList> 43 CArray(const ExtentList & sizes, const boost::general_storage_order<NumDims> & store); 46 // template <typename ExtentList> 47 // CArray(const ExtentList & sizes, const boost::general_storage_order<NumDims> & store); 48 template <typename ExtentList> CArray(const ExtentList & sizes, const boost::general_storage_order<NumDims> & store) 49 : boost::multi_array<ValueType, NumDims, Allocator> (sizes, store) 50 { /* Ne rien faire de plus */ } 44 51 45 52 CArray(const CArray & array); // NEVER IMPLEMENTED. … … 71 78 72 79 }; // class CArray 73 74 80 75 81 ///--------------------------------------------------------------- … … 77 83 } // namespace xios 78 84 79 #include "array_impl.hpp"85 //#include "array_impl.hpp" 80 86 #include "array_mac.hpp" 81 87 namespace xios 88 { 89 template <typename ValueType> void FromBinary(StdIStream & is, ARRAY(ValueType, 1) & array) ; 90 template <typename ValueType> void FromBinary(StdIStream & is, ARRAY(ValueType, 2) & array) ; 91 template <typename ValueType> void FromBinary(StdIStream & is, ARRAY(ValueType, 3) & array) ; 92 } 82 93 #endif // __XMLIO_CArray__
Note: See TracChangeset
for help on using the changeset viewer.