matrix.h
00001 #ifndef VVELIB_STORAGE_UTIL_MATRIX_H
00002 #define VVELIB_STORAGE_UTIL_MATRIX_H
00003
00008 #include <config.h>
00009 #include <storage/storage.h>
00010 #include <util/matrix.h>
00011
00012 namespace util
00013 {
00014 template <size_t nRows, size_t nCols, typename T>
00015 bool serialization(storage::VVEStorage& store, Matrix<nRows,nCols,T>& mat)
00016 {
00017 for(size_t i = 0 ; i < nRows ; ++i)
00018 {
00019 for(size_t j = 0 ; j < nCols ; ++j)
00020 {
00021 if(!store.field("V", mat(i,j)))
00022 return false;
00023 }
00024 }
00025 return true;
00026 };
00027 }
00028
00029 #endif // VVELIB_STORAGE_UTIL_MATRIX_H
00030