mzformatenumstr.cpp
Go to the documentation of this file.
/**
* \file pappsomspp/msfile/mzformatenumstr.cpp
* \date 12/2/2021
* \author Olivier Langella <olivier.langella@universite-paris-saclay.fr>
* \brief convert mzformat enumerations to strings
*
*/
/*******************************************************************************
* Copyright (c) 2021 Olivier Langella
*<olivier.langella@universite-paris-saclay.fr>.
*
* This file is part of the PAPPSOms++ library.
*
* PAPPSOms++ is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* PAPPSOms++ is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with PAPPSOms++. If not, see <http://www.gnu.org/licenses/>.
*
******************************************************************************/
#include "mzformatenumstr.h"
#include "../pappsoexception.h"
using namespace pappso;
const QString
pappso::MzFormatEnumStr::toString(pappso::MzFormat mz_format_enum)
{
QString mz_format_str;
switch(mz_format_enum)
{
case MzFormat::abSciexT2D:
mz_format_str = "abSciexT2D";
break;
case MzFormat::abSciexWiff:
mz_format_str = "abSciexWiff";
break;
case MzFormat::agilentMassHunter:
mz_format_str = "agilentMassHunter";
break;
case MzFormat::brukerBaf:
mz_format_str = "brukerBaf";
break;
case MzFormat::brukerFid:
mz_format_str = "brukerFid";
break;
case MzFormat::brukerTims:
mz_format_str = "brukerTims";
break;
case MzFormat::brukerYep:
mz_format_str = "brukerYep";
break;
case MzFormat::MGF:
mz_format_str = "MGF";
break;
case MzFormat::msn:
mz_format_str = "msn";
break;
case MzFormat::mz5:
mz_format_str = "mz5";
break;
case MzFormat::mzML:
mz_format_str = "mzML";
break;
case MzFormat::mzXML:
mz_format_str = "mzXML";
break;
case MzFormat::SQLite3:
mz_format_str = "SQLite3";
break;
case MzFormat::thermoRaw:
mz_format_str = "thermoRaw";
break;
case MzFormat::watersRaw:
mz_format_str = "watersRaw";
break;
case MzFormat::xy:
mz_format_str = "xy";
break;
default:
throw pappso::PappsoException(QObject::tr("MzFormat unknown :\n%1")
.arg((std::uint8_t)mz_format_enum));
}
return mz_format_str;
}
pappso::MzFormatEnumStr::toString
static const QString toString(MzFormat mz_format_enum)
convert mz format enumeration to human readable string
Definition: mzformatenumstr.cpp:36
pappso::PappsoException
Definition: pappsoexception.h:42
mzformatenumstr.h
convert mzformat enumerations to strings
pappso
tries to keep as much as possible monoisotopes, removing any possible C13 peaks and changes multichar...
Definition: aa.cpp:39
pappso::MzFormat
MzFormat
Definition: types.h:107
pappso::MzFormat::brukerTims
@ brukerTims
pappso::MzFormat::msn
@ msn
pappso::MzFormat::xy
@ xy
(x,y) format
pappso::MzFormat::agilentMassHunter
@ agilentMassHunter
pappso::MzFormat::abSciexT2D
@ abSciexT2D
pappso::MzFormat::mzXML
@ mzXML
mzXML
pappso::MzFormat::watersRaw
@ watersRaw
pappso::MzFormat::mz5
@ mz5
pappso::MzFormat::brukerBaf
@ brukerBaf
pappso::MzFormat::mzML
@ mzML
mzML
pappso::MzFormat::abSciexWiff
@ abSciexWiff
pappso::MzFormat::brukerFid
@ brukerFid
pappso::MzFormat::SQLite3
@ SQLite3
SQLite3 format.
pappso::MzFormat::MGF
@ MGF
Mascot format.
pappso::MzFormat::thermoRaw
@ thermoRaw
pappso::MzFormat::brukerYep
@ brukerYep