| 68 |
|
namespace OpenMD { |
| 69 |
|
|
| 70 |
|
void RestReader::scanFile(){ |
| 71 |
< |
int lineNo = 0; |
| 71 |
> |
|
| 72 |
|
std::streampos prevPos; |
| 73 |
|
std::streampos currPos; |
| 74 |
|
|
| 82 |
|
prevPos = currPos; |
| 83 |
|
|
| 84 |
|
bool foundOpenSnapshotTag = false; |
| 85 |
< |
|
| 85 |
> |
int lineNo = 0; |
| 86 |
|
while(!foundOpenSnapshotTag && inFile_->getline(buffer, bufferSize)) { |
| 87 |
|
++lineNo; |
| 88 |
|
|
| 368 |
|
|
| 369 |
|
// is this io restrained? |
| 370 |
|
GenericData* data = sd->getPropertyByName("Restraint"); |
| 371 |
– |
ObjectRestraint* oRest; |
| 371 |
|
|
| 372 |
|
if (data != NULL) { |
| 373 |
|
// make sure we can reinterpret the generic data as restraint data: |
| 375 |
|
if (restData != NULL) { |
| 376 |
|
// make sure we can reinterpet the restraint data as a pointer to |
| 377 |
|
// an ObjectRestraint: |
| 378 |
< |
oRest = dynamic_cast<ObjectRestraint*>(restData->getData()); |
| 378 |
> |
ObjectRestraint* oRest = dynamic_cast<ObjectRestraint*>(restData->getData()); |
| 379 |
|
if (oRest != NULL) { |
| 380 |
|
if (sd->isDirectional()) { |
| 381 |
|
oRest->setReferenceStructure(pos, q.toRotationMatrix3()); |