GCC Code Coverage Report


Directory: ./
File: src/Representation/PRustTraitBackendManager.h
Date: 2026-10-16 17:52:29
Exec Total Coverage
Lines: 3 3 100.0%
Functions: 1 1 100.0%
Branches: 4 7 57.1%

Line Branch Exec Source
1 /***************************************
2 Auteur : Pierre Aubert
3 Mail : pierre.aubert@lapp.in2p3.fr
4 Licence : LGPL-3.0-only
5 ****************************************/
6
7 #ifndef __PRUST_TRAIT_BACKEND_MANAGER_H__
8 #define __PRUST_TRAIT_BACKEND_MANAGER_H__
9
10 #include "PAbstractTraitBackend.h"
11
12 typedef std::vector<PAbstractRustTraitBackend*> PVecRustTraitBackend;
13
14 ///@brief Manager of the Rust trait backends
15 class PRustTraitBackendManager{
16 public:
17 PRustTraitBackendManager();
18 virtual ~PRustTraitBackendManager();
19
20 ///Add a trait backend into the PRustTraitBackendManager
21 template<class Backend>
22 1 void addTraitBackend(){
23
4/7
✓ Branch 0 (2→3) taken 1 times.
✓ Branch 2 (3→4) taken 1 times.
✓ Branch 4 (4→5) taken 1 times.
✗ Branch 6 (5→6) not taken.
✓ Branch 7 (5→7) taken 1 times.
✗ Branch 8 (8→9) not taken.
✗ Branch 9 (8→10) not taken.
1 p_vecTrait.push_back(new Backend);
24 1 }
25
26 void headerExtraInclude(std::ofstream & fs, const GeneratorMode & mode) const;
27 void implMethodDeclaration(std::ofstream & fs, const PClassConfig & classConfig, const GeneratorMode & mode) const;
28 void classExtraDeclaration(std::ofstream & fs, const PClassConfig & classConfig, const GeneratorMode & mode) const;
29
30 void testFunction(std::ofstream & fs, const PClassConfig & classConfig, const GeneratorMode & mode) const;
31
32 void clear();
33 private:
34 void initialisationPRustTraitBackendManager();
35
36 ///Vector of the Trait backend
37 PVecRustTraitBackend p_vecTrait;
38 };
39
40 #endif
41