LAMA
/home/brandes/workspace/LAMA/src/lama/LAMAArrayUtils.hpp
Go to the documentation of this file.
00001 
00033 #ifndef LAMA_LAMA_ARRAY_UTILS_HPP_
00034 #define LAMA_LAMA_ARRAY_UTILS_HPP_
00035 // for dll_import
00036 #include <lama/config.hpp>
00037 
00038 // others
00039 #include <lama/LAMAArray.hpp>
00040 
00041 // logging
00042 #include <logging/logging.hpp>
00043 
00044 namespace lama
00045 {
00046 
00049 class LAMA_DLL_IMPORTEXPORT LAMAArrayUtils
00050 {
00051 
00052 public:
00053 
00071     static void assign( _LAMAArray& target, const _LAMAArray& source );
00072 
00073     template<typename ValueType1, typename ValueType2>
00074     static void gather( LAMAArray<ValueType1>& target, 
00075                         const LAMAArray<ValueType2>& source, const LAMAArray<IndexType>& index );
00076 
00077     template<typename ValueType1>
00078     static void assign( LAMAArray<ValueType1>& target, const Scalar& value, ContextPtr context  );
00079 
00080 private:
00081 
00082     template<typename ValueType1, typename ValueType2>
00083     static void assignImpl2( LAMAArray<ValueType1>& target, const LAMAArray<ValueType2>& source );
00084 
00085     template<typename ValueType>
00086     static void assignImpl1( LAMAArray<ValueType>& target, const _LAMAArray& source );
00087 
00088     LAMA_LOG_DECL_STATIC_LOGGER( logger );
00089 };
00090 
00091 } // namespace
00092 
00093 #endif // LAMA_LAMA_ARRAY_UTILS_HPP_