Debian Codegraph @

qt6/src/poppler-qiodeviceoutstream-private.h

raw
1 /* poppler-qiodevicestream-private.h: Qt6 interface to poppler
2 * Copyright (C) 2008, Pino Toscano <[email protected]>
3 * Copyright (C) 2013 Adrian Johnson <[email protected]>
4 * Copyright (C) 2021, 2025 Albert Astals Cid <[email protected]>
5 * Copyright (C) 2021, Even Rouault <[email protected]>
6 * Copyright (C) 2024, g10 Code GmbH, Author: Sune Stolborg Vuorela <[email protected]>
7 *
8 * This program is free software; you can redistribute it and/or modify
9 * it under the terms of the GNU General Public License as published by
10 * the Free Software Foundation; either version 2, or (at your option)
11 * any later version.
12 *
13 * This program is distributed in the hope that it will be useful,
14 * but WITHOUT ANY WARRANTY; without even the implied warranty of
15 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16 * GNU General Public License for more details.
17 *
18 * You should have received a copy of the GNU General Public License
19 * along with this program; if not, write to the Free Software
20 * Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston, MA 02110-1301, USA.
21 */
22
23 #ifndef POPPLER_QIODEVICESTREAM_PRIVATE_H
24 #define POPPLER_QIODEVICESTREAM_PRIVATE_H
25
26 #include "Stream.h"
27
28 class QIODevice;
29
30 namespace Poppler {
31
32 class QIODeviceOutStream : public OutStream
33 {
34 public:
35 explicit QIODeviceOutStream(QIODevice *device);
36 ~QIODeviceOutStream() override;
37
38 void close() override;
39 Goffset getPos() override;
40 void put(char c) override;
41 size_t write(std::span<const unsigned char> data) override;
42 void printf(const char *format, ...) override GCC_PRINTF_FORMAT(2, 3);
43
44 private:
45 QIODevice *m_device;
46 };
47
48 }
49
50 #endif