NameAssignment::NameAssignment(string nameMapFile){
m = MothurOut::getInstance();
- openInputFile(nameMapFile, fileHandle);
+ m->openInputFile(nameMapFile, fileHandle);
}
-
+//**********************************************************************************************************************
+NameAssignment::NameAssignment(){ m = MothurOut::getInstance(); }
//**********************************************************************************************************************
void NameAssignment::readMap(){
try{
string firstCol, secondCol, skip;
// int index = 0;
-
+
map<string, int>::iterator itData;
int rowIndex = 0;
while(fileHandle){
- fileHandle >> firstCol; //read from first column
+ fileHandle >> firstCol; m->gobble(fileHandle); //read from first column
fileHandle >> secondCol; //read from second column
itData = (*this).find(firstCol);
}else{ m->mothurOut(firstCol + " is already in namesfile. I will use first definition."); m->mothurOutEndLine(); }
- gobble(fileHandle);
+ m->gobble(fileHandle);
}
fileHandle.close();