Loading...
Searching...
No Matches
mzidentmlwriter.h
Go to the documentation of this file.
/**
* \file processing/xml/mzidentmlwriter.h
* \date 07/02/2024
* \author Olivier Langella
* \brief MzIdentML writer
*/
/*******************************************************************************
* Copyright (c) 2024 Olivier Langella
*<Olivier.Langella@universite-paris-saclay.fr>.
*
* This file is part of PAPPSOms-tools.
*
* PAPPSOms-tools 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-tools 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-tools. If not, see <http://www.gnu.org/licenses/>.
*
******************************************************************************/
#pragma once
#include <QString>
#include <QXmlStreamWriter>
#include "../../types.h"
#include "../../psm/deepprot/deepprotenum.h"
#include "../../amino_acid/aamodification.h"
#include "../../protein/protein.h"
#include "pappsomspp/export-import-config.h"
namespace pappso
{
/**
* @todo write docs
*/
class PMSPP_LIB_DECL MzIdentMlWriter : public QXmlStreamWriter
{
public:
/**
* Default constructor
*/
MzIdentMlWriter();
/**
* Destructor
*/
virtual ~MzIdentMlWriter();
void writeDBSequence(const QString &id,
const QString &db_ref_id,
const pappso::Protein &protein,
bool is_reverse);
void writeDBSequence(const QString &id,
const QString &db_ref_id,
const QString &accession,
const QString &description,
const QString &sequence,
bool is_reverse);
void writeStartMzIdentMlDocument(const QString &id, const QString &version);
void writeCvList();
void writeCvParam(pappso::AaModificationP modification);
void writeCvParam(const pappso::OboPsiModTerm &term, const QString &value);
void writeCvParam(const QString &cv_ref,
const QString &accession,
const QString &name,
const QString &value);
void writeCvParamUo(const QString &cv_ref,
const QString &accession,
const QString &name,
const QString &value,
const QString &unit_cv_ref,
const QString &unit_accession,
const QString &unit_name);
void writeCvParamUo(const QString &cv_ref,
const QString &accession,
const QString &name,
const QString &value,
Enums::PrecisionUnit precision_unit);
void writeUserParam(const QString &name, const QString &value);
void writeUserParam(const QString &name, double value);
void writeUserParam(pappso::DeepProtMatchType matchType);
void writeUserParam(pappso::DeepProtPeptideCandidateStatus status);
static const QString toXmlMass(double mass);
static const QString toXmlMassDelta(double mass);
static const QString toXmlDouble(double value);
private:
// QString m_mzidentmlNamespace = "http://psidev.info/psi/pi/mzIdentML/1.2";
};
} // namespace pappso
aamodification.h
pappso::MzIdentMlWriter::toXmlMassDelta
static const QString toXmlMassDelta(double mass)
Definition mzidentmlwriter.cpp:329
pappso::MzIdentMlWriter::MzIdentMlWriter
MzIdentMlWriter()
Definition mzidentmlwriter.cpp:33
pappso::MzIdentMlWriter::toXmlDouble
static const QString toXmlDouble(double value)
Definition mzidentmlwriter.cpp:341
pappso::MzIdentMlWriter::writeDBSequence
void writeDBSequence(const QString &id, const QString &db_ref_id, const pappso::Protein &protein, bool is_reverse)
Definition mzidentmlwriter.cpp:116
pappso::MzIdentMlWriter::writeCvList
void writeCvList()
Definition mzidentmlwriter.cpp:72
pappso::MzIdentMlWriter::writeStartMzIdentMlDocument
void writeStartMzIdentMlDocument(const QString &id, const QString &version)
Definition mzidentmlwriter.cpp:42
pappso::MzIdentMlWriter::writeCvParamUo
void writeCvParamUo(const QString &cv_ref, const QString &accession, const QString &name, const QString &value, const QString &unit_cv_ref, const QString &unit_accession, const QString &unit_name)
Definition mzidentmlwriter.cpp:255
pappso::MzIdentMlWriter::writeCvParam
void writeCvParam(pappso::AaModificationP modification)
Definition mzidentmlwriter.cpp:226
pappso::MzIdentMlWriter::toXmlMass
static const QString toXmlMass(double mass)
Definition mzidentmlwriter.cpp:323
pappso::MzIdentMlWriter::writeUserParam
void writeUserParam(const QString &name, const QString &value)
Definition mzidentmlwriter.cpp:301
pappso::OboPsiModTerm
Definition obopsimodterm.h:34
pappso::Protein
Definition protein.h:50
deepprotenum.h
export-import-config.h
PMSPP_LIB_DECL
#define PMSPP_LIB_DECL
Definition export-import-config.h:14
pappso::Enums::PrecisionUnit
PrecisionUnit
Definition types.h:96
pappso
tries to keep as much as possible monoisotopes, removing any possible C13 peaks and changes multichar...
Definition aa.cpp:39
pappso::AaModificationP
const AaModification * AaModificationP
Definition aamodification.h:52
pappso::DeepProtMatchType
DeepProtMatchType
definition of different class of PSMs used by DeepProt
Definition deepprotenum.h:42
pappso::DeepProtPeptideCandidateStatus
DeepProtPeptideCandidateStatus
definition of different status for potential peptide candidates on the same spectrum
Definition deepprotenum.h:61
protein.h
types.h