LOG4CPLUS_ERROR(logger,"Could not determine file type of "<<transitionSystemFile<<". Filename suggests "<<name<<" but transitions look like "<<transitions);LOG4CPLUS_ERROR(logger,"Please fix your file and try again.");
throwstorm::exceptions::WrongFileFormatException()<<"Could not determine type of file "<<transitionSystemFile;
}
}else{
if((hint==name)&&(name==transitions))type=name;
elseif(hint==name){
LOG4CPLUS_WARN(logger,"Transition format in file "<<transitionSystemFile<<" of type "<<name<<" look like "<<transitions<<" transitions.");
LOG4CPLUS_WARN(logger,"We will use the parser for "<<name<<" and hope for the best!");
type=name;
}
elseif(hint==transitions){
LOG4CPLUS_WARN(logger,"File extension of "<<transitionSystemFile<<" suggests type "<<name<<" but the content seems to be "<<hint);
LOG4CPLUS_WARN(logger,"We will use the parser for "<<hint<<" and hope for the best!");
type=hint;
}
elseif(name==transitions){
LOG4CPLUS_WARN(logger,"File "<<transitionSystemFile<<" contains a hint that it is "<<hint<<" but filename and transition pattern suggests "<<name);
LOG4CPLUS_WARN(logger,"We will use the parser for "<<name<<" and hope for the best!");
type=name;
}
else{
LOG4CPLUS_WARN(logger,"File "<<transitionSystemFile<<" contains a hint that it is "<<hint<<" but filename suggests "<<name<<" and transition pattern suggests "<<transitions);
LOG4CPLUS_WARN(logger,"We will stick to the hint, use the parser for "<<hint<<" and hope for the best!");
type=hint;
}
if(type==storm::models::Unknown){
LOG4CPLUS_ERROR(logger,"Could not determine file type of "<<transitionSystemFile<<".");
LOG4CPLUS_ERROR(logger,"The first line of the file should contain a format hint. Please fix your file and try again.");
throwstorm::exceptions::WrongFileFormatException()<<"Could not determine type of file "<<transitionSystemFile;
}
else{
LOG4CPLUS_INFO(logger,"Model type seems to be "<<type);
}
// Do actual parsing
@ -65,26 +41,13 @@ AutoParser::AutoParser(std::string const & transitionSystemFile, std::string con