Changeset 1742 in Sophya for trunk/ArchTOIPipe
- Timestamp:
- Nov 10, 2001, 12:13:15 AM (24 years ago)
- Location:
- trunk/ArchTOIPipe/Kernel
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/ArchTOIPipe/Kernel/toi.cc
r1740 r1742 3 3 // Christophe Magneville 4 4 // Reza Ansari 5 // $Id: toi.cc,v 1. 8 2001-11-08 23:23:58aubourg Exp $5 // $Id: toi.cc,v 1.9 2001-11-09 23:13:14 aubourg Exp $ 6 6 7 7 #include "toiprocessor.h" … … 117 117 */ 118 118 119 double TOI::getData(int i) { 119 double TOI::getData(int i) { /* deprecated, overriden in toisegment */ 120 120 lock(); 121 121 uint_8 flg; … … 127 127 } 128 128 129 void TOI::getData(int i, double &data, uint_8 &flag) { 129 void TOI::getData(int i, double &data, uint_8 &flag) { /* deprecated, overriden in toisegment */ 130 130 lock(); 131 131 doGetData(i, data, flag); … … 135 135 } 136 136 137 138 139 void TOI::putData(int i, double value, uint_8 flag) { 137 void TOI::getData(int i, int n, double* data, uint_8* flg) { 138 cerr << "TOI::getData [double*] unimplemented" << endl; 139 exit(-1); 140 } 141 142 void TOI::putData(int i, int n, double const* var, uint_8 const* flg) { 143 cerr << "TOI::putData [double*] unimplemented" << endl; 144 exit(-1); 145 } 146 147 void TOI::putData(int i, double value, uint_8 flag) { /* deprecated, overriden in toisegment */ 140 148 lock(); 141 149 doPutData(i, value, flag); … … 144 152 } 145 153 146 void TOI::waitForData(int iStart, int iEnd) { 154 void TOI::waitForData(int iStart, int iEnd) { /* deprecated, overriden in toisegment */ 147 155 if (producer == NULL) throw NotFoundExc("TOI has no producer !"); 148 156 … … 163 171 } 164 172 165 void TOI::waitForData(int i) { 173 void TOI::waitForData(int i) { /* deprecated, overriden in toisegment */ 166 174 waitForData(i,i); 167 175 } 168 176 169 void TOI::waitForAnyData() { 177 void TOI::waitForAnyData() { /* deprecated, overriden in toisegment */ 170 178 if (! hasSomeData()) { 171 179 producer->lock(); … … 193 201 } 194 202 195 void TOI::wontNeedBefore(int i) { 203 void TOI::wontNeedBefore(int i) { /* deprecated, overriden in toisegment */ 196 204 int j=i; 197 205 for (vector<TOIProcessor*>::iterator k = consumers.begin(); -
trunk/ArchTOIPipe/Kernel/toi.h
r1740 r1742 5 5 // Christophe Magneville 6 6 // Reza Ansari 7 // $Id: toi.h,v 1.1 0 2001-11-08 23:23:58aubourg Exp $7 // $Id: toi.h,v 1.11 2001-11-09 23:13:15 aubourg Exp $ 8 8 9 9 #ifndef TOI_H … … 52 52 virtual void getData(int i, double &data, uint_8 &flag); 53 53 //RZCMV virtual DataStatus getDataError(int i,double &data,double &error,int_4 &flag); 54 virtual void getData(int i, int n, double* data, uint_8* flg=0); 54 55 55 56 virtual DataStatus isDataAvail(int iStart, int iEnd); … … 64 65 //RZCMV virtual void putDataError(int i, double value, 65 66 // double error, int_4 flag=0); 67 virtual void putData(int i, int n, double const* val, uint_8 const* flg); 66 68 virtual void putDone() {} 67 69 -
trunk/ArchTOIPipe/Kernel/toiprocessor.cc
r1740 r1742 3 3 // Christophe Magneville 4 4 // Reza Ansari 5 // $Id: toiprocessor.cc,v 1.1 4 2001-11-08 23:23:58aubourg Exp $5 // $Id: toiprocessor.cc,v 1.15 2001-11-09 23:13:15 aubourg Exp $ 6 6 7 7 #include "toiprocessor.h" … … 321 321 if (toi->needSyncOldWay()) toi->waitForData(i); // seulement pour autre que segmented 322 322 toi->getData(i, data, flag); 323 autoWontNeed(i); 323 324 return; 324 325 } 326 327 void TOIProcessor::getData(int toiIndex, int i, int n, double* d) 328 { 329 TOI* toi = getInputTOI(toiIndex); 330 if (toi->needSyncOldWay()) toi->waitForData(i+n); // seulement pour autre que segmented 331 toi->getData(i, n, d); 332 autoWontNeed(i); 333 return; 334 } 335 336 void TOIProcessor::getData(int toiIndex, int i, int n, double* d, uint_8* f) 337 { 338 TOI* toi = getInputTOI(toiIndex); 339 if (toi->needSyncOldWay()) toi->waitForData(i+n); // seulement pour autre que segmented 340 toi->getData(i, n, d, f); 341 autoWontNeed(i); 342 return; 343 } 344 325 345 326 346 /*RZCMV … … 369 389 TOI* toi = getOutputTOI(toiIndex); 370 390 toi->putData(i, value, flg); 371 autoWontNeed(i); 391 // autoWontNeed(i); // now done on getData 392 if (toi->needSyncOldWay()) notify(); // seulement pour non segmented 393 } 394 395 void TOIProcessor::putData(int toiIndex, int i, int n, double const* val, 396 uint_8 const* flg=0) { 397 TOI* toi = getOutputTOI(toiIndex); 398 toi->putData(i, n, val, flg); 372 399 if (toi->needSyncOldWay()) notify(); // seulement pour non segmented 373 400 }
Note:
See TracChangeset
for help on using the changeset viewer.