Skip to content
Snippets Groups Projects
Commit 2d0b5e34 authored by Langella Olivier's avatar Langella Olivier
Browse files

first fix for issue #23

parent d45a245f
No related branches found
No related tags found
No related merge requests found
......@@ -42,7 +42,7 @@ class IdentificationDataSource
public:
IdentificationDataSource(const QString resource_name);
IdentificationDataSource(const IdentificationDataSource &other);
~IdentificationDataSource();
virtual ~IdentificationDataSource();
PeptideEvidenceStore &getPeptideEvidenceStore();
const PeptideEvidenceStore &getPeptideEvidenceStore() const;
......
......@@ -50,6 +50,7 @@ IdentificationDataSourceSp
IdentificationDataSourceStore::getInstance(const QString &location,
IdentificationEngine engine)
{
//TODO file format read needs a fix
qDebug() << "IdentificationDataSourceStore::getInstance begin " << location;
std::map<QString, IdentificationDataSourceSp>::iterator it =
_map_identification_data_sources.find(location);
......@@ -75,11 +76,13 @@ IdentificationDataSourceStore::getInstance(const QString &location,
else if(ext.toLower() == "pep")
{
// pep xml file
p_identfile = std::make_shared<IdentificationPwizFile>(location_file);
// p_identfile =
// std::make_shared<IdentificationPwizFile>(location_file);
}
else
{
//p_identfile = std::make_shared<IdentificationPwizFile>(location_file);
// p_identfile =
// std::make_shared<IdentificationPwizFile>(location_file);
}
if(p_identfile == nullptr)
{
......@@ -123,7 +126,7 @@ IdentificationDataSourceStore::getInstance(const QString &location)
QString ext = location_file.completeSuffix();
// QString sample_name = location_file.baseName();
IdentificationDataSourceSp p_identfile = nullptr;
if(ext.toLower() == "xml")
if((ext.toLower() == "xml") || (ext.toLower() == ".d.xml"))
{
// X!Tandem result file
p_identfile =
......@@ -144,8 +147,8 @@ IdentificationDataSourceStore::getInstance(const QString &location)
else if(ext.toLower() == "pepxml")
{
// pep xml file
p_identfile =
std::make_shared<IdentificationPepXmlFile>(location_file);
// p_identfile =
// std::make_shared<IdentificationPepXmlFile>(location_file);
}
else if(ext.toLower() == "dat")
{
......@@ -155,7 +158,8 @@ IdentificationDataSourceStore::getInstance(const QString &location)
}
else
{
p_identfile = std::make_shared<IdentificationPwizFile>(location_file);
// p_identfile =
// std::make_shared<IdentificationPwizFile>(location_file);
}
if(p_identfile == nullptr)
{
......
......@@ -30,8 +30,7 @@
*implementation
******************************************************************************/
#ifndef IDENTIFICATIONDATASOURCESTORE_H
#define IDENTIFICATIONDATASOURCESTORE_H
#pragma once
#include <map>
#include <set>
......@@ -54,5 +53,3 @@ class IdentificationDataSourceStore
std::map<QString, IdentificationDataSourceSp>
_map_identification_data_sources;
};
#endif // IDENTIFICATIONDATASOURCESTORE_H
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment