libpappsomspp
Library for mass spectrometry
Loading...
Searching...
No Matches
proteinintegercode.h
Go to the documentation of this file.
1/**
2 * \file protein/proteinintegercode.h
3 * \date 22/05/2023
4 * \author Olivier Langella
5 * \brief transform protein amino acid sequence into vectors of amino acid codes
6 */
7
8/*******************************************************************************
9 * Copyright (c) 2023 Olivier Langella
10 *<Olivier.Langella@universite-paris-saclay.fr>.
11 *
12 * This file is part of PAPPSOms-tools.
13 *
14 * PAPPSOms-tools is free software: you can redistribute it and/or modify
15 * it under the terms of the GNU General Public License as published by
16 * the Free Software Foundation, either version 3 of the License, or
17 * (at your option) any later version.
18 *
19 * PAPPSOms-tools is distributed in the hope that it will be useful,
20 * but WITHOUT ANY WARRANTY; without even the implied warranty of
21 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
22 * GNU General Public License for more details.
23 *
24 * You should have received a copy of the GNU General Public License
25 * along with PAPPSOms-tools. If not, see <http://www.gnu.org/licenses/>.
26 *
27 ******************************************************************************/
28
29#pragma once
30
31#include "../exportinmportconfig.h"
32#include "../amino_acid/aastringcodec.h"
33#include "protein.h"
34#include <vector>
35
36namespace pappso
37{
38
39/**
40 * @brief
41 */
43{
44 public:
45 /**
46 * Default constructor
47 */
49 const AaStringCodec &codec,
50 std::size_t aa_str_max_size = 5);
51
52 /**
53 * Copy constructor
54 *
55 * @param other TODO
56 */
58
59 /**
60 * Destructor
61 */
63
64 const std::vector<std::uint32_t> &
65 getPeptideCodedFragment(std::size_t size) const;
66
67 std::vector<std::pair<std::size_t, std::uint32_t>>
68 match(const std::vector<uint32_t> &code_list) const;
69
70 private:
71 std::vector<std::uint32_t>
72 computePeptideCodeFragments(const AaStringCodec &codec,
73 std::size_t fragment_size) const;
74
75 private:
77
78 std::vector<std::uint8_t> m_seqAaCode;
79 std::vector<std::vector<std::uint32_t>> m_peptideCodedFragments;
80};
81
82} // namespace pappso
std::vector< std::uint8_t > m_seqAaCode
std::vector< std::vector< std::uint32_t > > m_peptideCodedFragments
#define PMSPP_LIB_DECL
tries to keep as much as possible monoisotopes, removing any possible C13 peaks and changes multichar...
Definition aa.cpp:39
std::shared_ptr< const Protein > ProteinSp
shared pointer on a Protein object
Definition protein.h:47
object to handle a protein