libpappsomspp
Library for mass spectrometry
Loading...
Searching...
No Matches
jsoninput.h
Go to the documentation of this file.
1
2/**
3 * \file pappsomspp/masschroq/input/jsoninput.h
4 * \date 02/01/2025
5 * \author Olivier Langella
6 * \brief process json document input
7 */
8
9/*******************************************************************************
10 * Copyright (c) 2025 Olivier Langella
11 *<Olivier.Langella@universite-paris-saclay.fr>.
12 *
13 * This file is part of MassChroQ.
14 *
15 * MassChroQ is free software: you can redistribute it and/or modify
16 * it under the terms of the GNU General Public License as published by
17 * the Free Software Foundation, either version 3 of the License, or
18 * (at your option) any later version.
19 *
20 * MassChroQ is distributed in the hope that it will be useful,
21 * but WITHOUT ANY WARRANTY; without even the implied warranty of
22 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
23 * GNU General Public License for more details.
24 *
25 * You should have received a copy of the GNU General Public License
26 * along with MassChroQ. If not, see <http://www.gnu.org/licenses/>.
27 *
28 ******************************************************************************/
29
30#pragma once
31
32
35#include <QJsonDocument>
37#include "../msrungroup.h"
39
40namespace pappso::masschroq
41{
42
43/**
44 * @todo write docs
45 */
47{
48 public:
49 /**
50 * Default constructor
51 */
53 const QString &tmp_dir_name,
54 const QJsonDocument &json_doc);
55
56 /**
57 * Destructor
58 */
59 ~JsonInput();
60
61 void action(CborOutputStream &cbor_output);
62
63 private:
64 const QJsonValue documentFind(const QString &key1, const QString &key2) const;
65 void readMzDataFiles();
69 void read_protein_list();
70 void read_peptide_list();
72 void readAction(CborOutputStream &cbor_output);
73
74 void computeIsotopologues(double ni_ratio);
75
76 private:
77 const QJsonDocument &m_jsonDocument;
78 const QString &m_tmpDirName;
80
81
82 std::map<QString, MsRunPeptideListSp> m_msfileList;
85 std::map<QString, ProteinSp> m_proteinMap;
86 std::vector<PeptideSp> m_peptideStore;
87 std::map<QString, PeptideSp> m_peptideMap;
88 std::map<QString, MsRunGroupSp> m_msRunGroupSpList;
89
90 std::shared_ptr<pappso::IonMobilityGrid> msp_ionMobilityGrid;
91
93
95};
96} // namespace pappso::masschroq
const QJsonDocument & m_jsonDocument
Definition jsoninput.h:77
std::vector< PeptideSp > m_peptideStore
Definition jsoninput.h:86
std::map< QString, MsRunGroupSp > m_msRunGroupSpList
Definition jsoninput.h:88
const QString & m_tmpDirName
Definition jsoninput.h:78
pappso::UiMonitorInterface & m_uiMonitor
Definition jsoninput.h:79
void computeIsotopologues(double ni_ratio)
std::map< QString, PeptideSp > m_peptideMap
Definition jsoninput.h:87
void readAction(CborOutputStream &cbor_output)
std::map< QString, ProteinSp > m_proteinMap
Definition jsoninput.h:85
pappso::ProjectParameters m_projectParameters
Definition jsoninput.h:92
JsonInput(pappso::UiMonitorInterface &ui_monitor, const QString &tmp_dir_name, const QJsonDocument &json_doc)
Definition jsoninput.cpp:42
AlignmentMethodSp msp_alignmentMethod
Definition jsoninput.h:83
QuantificationMethodSp msp_quantificationMethod
Definition jsoninput.h:84
void action(CborOutputStream &cbor_output)
Definition jsoninput.cpp:54
std::map< QString, MsRunPeptideListSp > m_msfileList
Definition jsoninput.h:82
const QJsonValue documentFind(const QString &key1, const QString &key2) const
std::shared_ptr< pappso::IonMobilityGrid > msp_ionMobilityGrid
Definition jsoninput.h:90
#define PMSPP_LIB_DECL
std::shared_ptr< QuantificationMethod > QuantificationMethodSp
std::shared_ptr< AlignmentMethod > AlignmentMethodSp