GCC Code Coverage Report


Directory: gridformat/
File: gridformat/vtk/pvtp_reader.hpp
Date: 2024-11-10 16:24:00
Exec Total Coverage
Lines: 11 11 100.0%
Functions: 4 4 100.0%
Branches: 7 14 50.0%

Line Branch Exec Source
1 // SPDX-FileCopyrightText: 2022-2023 Dennis Gläser <dennis.glaeser@iws.uni-stuttgart.de>
2 // SPDX-License-Identifier: MIT
3 /*!
4 * \file
5 * \ingroup VTK
6 * \copydoc GridFormat::PVTPReader
7 */
8 #ifndef GRIDFORMAT_VTK_PVTP_READER_HPP_
9 #define GRIDFORMAT_VTK_PVTP_READER_HPP_
10
11 #include <optional>
12
13 #include <gridformat/vtk/vtp_reader.hpp>
14 #include <gridformat/vtk/pxml_reader.hpp>
15
16 namespace GridFormat {
17
18 /*!
19 * \ingroup VTK
20 * \brief Reader for .pvtp file format
21 * \copydetails VTK::PXMLUnstructuredGridReader
22 */
23 class PVTPReader : public VTK::PXMLUnstructuredGridReader<VTPReader> {
24 using ParentType = VTK::PXMLUnstructuredGridReader<VTPReader>;
25
26 public:
27 1 PVTPReader()
28
2/4
✓ Branch 1 taken 1 times.
✗ Branch 2 not taken.
✓ Branch 4 taken 1 times.
✗ Branch 5 not taken.
2 : ParentType("PPolyData")
29 1 {}
30
31 48 explicit PVTPReader(const NullCommunicator&)
32
2/4
✓ Branch 1 taken 48 times.
✗ Branch 2 not taken.
✓ Branch 4 taken 48 times.
✗ Branch 5 not taken.
96 : ParentType("PPolyData")
33 48 {}
34
35 template<Concepts::Communicator C>
36 84 explicit PVTPReader(const C& comm, std::optional<bool> merge_exceeding_pieces = {})
37
2/4
✓ Branch 1 taken 84 times.
✗ Branch 2 not taken.
✓ Branch 4 taken 84 times.
✗ Branch 5 not taken.
168 : ParentType("PPolyData", comm, merge_exceeding_pieces)
38 84 {}
39
40 private:
41 2 std::string _name() const override {
42
1/2
✓ Branch 1 taken 2 times.
✗ Branch 2 not taken.
4 return "PVTPReader";
43 }
44 };
45
46 } // namespace GridFormat
47
48 #endif // GRIDFORMAT_VTK_PVTP_READER_HPP_
49