Coverage Report

Created: 2026-04-29 07:28

next uncovered line (L), next uncovered region (R), next uncovered branch (B)
/src/libqxp/src/lib/QXPCollector.h
Line
Count
Source
1
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
2
/*
3
 * This file is part of the libqxp project.
4
 *
5
 * This Source Code Form is subject to the terms of the Mozilla Public
6
 * License, v. 2.0. If a copy of the MPL was not distributed with this
7
 * file, You can obtain one at http://mozilla.org/MPL/2.0/.
8
 */
9
10
#ifndef QXPCOLLECTOR_H_INCLUDED
11
#define QXPCOLLECTOR_H_INCLUDED
12
13
#include "libqxp_utils.h"
14
15
namespace libqxp
16
{
17
18
struct Box;
19
struct Group;
20
struct Line;
21
struct Page;
22
struct QXPDocumentProperties;
23
struct Text;
24
struct TextBox;
25
struct TextPath;
26
27
class QXPCollector
28
{
29
  // disable copying
30
  QXPCollector(const QXPCollector &other) = delete;
31
  QXPCollector &operator=(const QXPCollector &other) = delete;
32
33
public:
34
12.1k
  QXPCollector() = default;
35
12.1k
  virtual ~QXPCollector() = default;
36
37
0
  virtual void startDocument() { }
38
0
  virtual void endDocument() { }
39
40
2.75k
  virtual void startPage(const Page &) { }
41
1.96k
  virtual void endPage() { }
42
43
0
  virtual void collectDocumentProperties(const QXPDocumentProperties &) { }
44
45
1.01k
  virtual void collectLine(const std::shared_ptr<Line> &) { }
46
953
  virtual void collectBox(const std::shared_ptr<Box> &) { }
47
3.45k
  virtual void collectTextBox(const std::shared_ptr<TextBox> &) { }
48
1.83k
  virtual void collectTextPath(const std::shared_ptr<TextPath> &) { }
49
910
  virtual void collectGroup(const std::shared_ptr<Group> &) { }
50
51
524
  virtual void collectText(const std::shared_ptr<Text> &, const unsigned) { }
52
};
53
54
class QXPDummyCollector : public QXPCollector
55
{
56
public:
57
5.44k
  QXPDummyCollector() = default;
58
};
59
60
}
61
62
#endif // QXPCOLLECTOR_H_INCLUDED
63
64
/* vim:set shiftwidth=2 softtabstop=2 expandtab: */