LibKEduVocDocument

readermanager.h
1/*
2 * SPDX-FileCopyrightText: 2014 Andreas Xavier <andxav at zoho dot com>
3 * SPDX-License-Identifier: GPL-2.0-or-later
4 */
5
6#ifndef READERMANAGER_H
7#define READERMANAGER_H
8
9#include "keduvocdocument.h"
10
11#include <QIODevice>
12#include <QSharedPointer>
13class ReaderBase;
14
15/**
16 * @brief manages the choice of readers.
17 * @details When ReaderManager goes out of scope it frees its reader.
18 * */
20{
21public:
22 /** @brief a QSharedPointer to the ReaderBase class.*/
24
25 /** @brief returns a reader that can read this device.
26 @details The device must be open for read and seekable.
27 The manager checks all the readers that are known. If none of
28 them can parse this file/device it returns a BadReader.
29 @param device an open readable, non-sequential device.
30 @return a QSharedPointer<ReaderBase> for the device. */
31 static ReaderPtr reader(QIODevice &device);
32};
33
34#endif // READERMANAGER_H
a base class for readers of various lexicon formats
Definition readerbase.h:20
manages the choice of readers.
QSharedPointer< ReaderBase > ReaderPtr
a QSharedPointer to the ReaderBase class.
static ReaderPtr reader(QIODevice &device)
returns a reader that can read this device.
This file is part of the KDE documentation.
Documentation copyright © 1996-2024 The KDE developers.
Generated on Sat Dec 21 2024 17:05:43 by doxygen 1.12.0 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.