Changeset 2695 in Sophya for trunk/SophyaLib/BaseTools
- Timestamp:
- Apr 26, 2005, 6:20:21 PM (20 years ago)
- Location:
- trunk/SophyaLib/BaseTools
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/SophyaLib/BaseTools/ppfswapper.h
r2660 r2695 23 23 class PPFDataSwapper : public DataSwapperInterface<T> { 24 24 public: 25 PPFDataSwapper() { ppfos = NULL; ppfis = NULL;} 25 26 PPFDataSwapper(POutPersist & os) { ppfos = &os; ppfis = NULL;} 26 27 PPFDataSwapper(PInPersist & is) { ppfos = NULL; ppfis = &is;} -
trunk/SophyaLib/BaseTools/ppftpointerio.cc
r2687 r2695 102 102 103 103 } // namespace SOPHYA 104 /* 104 105 #ifdef __CXX_PRAGMA_TEMPLATES__ 105 106 #pragma define_template PPF_TPointer_IO< char > … … 133 134 template class PPF_TPointer_IO< complex<r_8> >; 134 135 #endif 135 136 */ -
trunk/SophyaLib/BaseTools/ppftpointerio.h
r2687 r2695 37 37 }; 38 38 39 // declaration specifique pour ecriture sous forme de tableaux PPF 40 class PPF_TPointer_IO<char> { 41 public: 42 static void Write(POutPersist & os, char const * arr, size_t n); 43 static void Read(PInPersist & is, char * arr, size_t n); 44 }; 45 46 class PPF_TPointer_IO<int_1> { 47 public: 48 static void Write(POutPersist & os, int_1 const * arr, size_t n); 49 static void Read(PInPersist & is, int_1 * arr, size_t n); 50 }; 51 class PPF_TPointer_IO<uint_1> { 52 public: 53 static void Write(POutPersist & os, uint_1 const * arr, size_t n); 54 static void Read(PInPersist & is, uint_1 * arr, size_t n); 55 }; 56 57 class PPF_TPointer_IO<int_2> { 58 public: 59 static void Write(POutPersist & os, int_2 const * arr, size_t n); 60 static void Read(PInPersist & is, int_2 * arr, size_t n); 61 }; 62 class PPF_TPointer_IO<uint_2> { 63 public: 64 static void Write(POutPersist & os, uint_2 const * arr, size_t n); 65 static void Read(PInPersist & is, uint_2 * arr, size_t n); 66 }; 67 68 class PPF_TPointer_IO<int_4> { 69 public: 70 static void Write(POutPersist & os, int_4 const * arr, size_t n); 71 static void Read(PInPersist & is, int_4 * arr, size_t n); 72 }; 73 class PPF_TPointer_IO<uint_4> { 74 public: 75 static void Write(POutPersist & os, uint_4 const * arr, size_t n); 76 static void Read(PInPersist & is, uint_4 * arr, size_t n); 77 }; 78 79 class PPF_TPointer_IO<int_8> { 80 public: 81 static void Write(POutPersist & os, int_8 const * arr, size_t n); 82 static void Read(PInPersist & is, int_8 * arr, size_t n); 83 }; 84 class PPF_TPointer_IO<uint_8> { 85 public: 86 static void Write(POutPersist & os, uint_8 const * arr, size_t n); 87 static void Read(PInPersist & is, uint_8 * arr, size_t n); 88 }; 89 90 class PPF_TPointer_IO<r_4> { 91 public: 92 static void Write(POutPersist & os, r_4 const * arr, size_t n); 93 static void Read(PInPersist & is, r_4 * arr, size_t n); 94 }; 95 class PPF_TPointer_IO<r_8> { 96 public: 97 static void Write(POutPersist & os, r_8 const * arr, size_t n); 98 static void Read(PInPersist & is, r_8 * arr, size_t n); 99 }; 100 101 class PPF_TPointer_IO< complex<r_4> > { 102 public: 103 static void Write(POutPersist & os, complex<r_4> const * arr, size_t n); 104 static void Read(PInPersist & is, complex<r_4> * arr, size_t n); 105 }; 106 class PPF_TPointer_IO< complex<r_8> > { 107 public: 108 static void Write(POutPersist & os, complex<r_8> const * arr, size_t n); 109 static void Read(PInPersist & is, complex<r_8> * arr, size_t n); 110 }; 39 111 40 112 } // namespace SOPHYA -
trunk/SophyaLib/BaseTools/swsegdb.h
r2692 r2695 120 120 mSRef = a.mSRef; 121 121 mSRef->nref++; 122 return *this; 122 123 } 123 124 124 //! Return the position tag (swap position) table125 std::vector< int_8 > & GetSwapPosTagTable() const126 { 125 //! Empties all memory buffers to swap stream 126 void SwapOutBuffer() const 127 { 127 128 if ((mSRef->bidx >= 0) && !mSRef->fgcstbuff) { 128 129 int_8 nswp = mSRef->swapper->WriteToSwap(mSRef->buff, mSRef->segsize, mSRef->bidx, … … 130 131 mSRef->swp[mSRef->bidx] = nswp; 131 132 mSRef->fgwp[mSRef->bidx] = true; 132 } 133 mSRef->bidx = -1; 134 mSRef->fgcstbuff = true; 135 } 136 } 137 //! Return the position tag (swap position) table, after call to SwapOutBuffer() 138 std::vector< int_8 > & GetSwapPosTagTable() const 139 { 140 SwapOutBuffer(); 133 141 return mSRef->swp; 134 142 }
Note:
See TracChangeset
for help on using the changeset viewer.