File indexing completed on 2024-04-28 15:39:19
0001 /* 0002 SPDX-FileCopyrightText: 2022 Friedrich W. H. Kossebau <kossebau@kde.org> 0003 0004 SPDX-License-Identifier: LGPL-2.1-or-later 0005 */ 0006 0007 #ifndef KODASKANNA_IMAGESOURCE_IMAGEREADRESULT_HPP 0008 #define KODASKANNA_IMAGESOURCE_IMAGEREADRESULT_HPP 0009 0010 // Qt 0011 #include <QExplicitlySharedDataPointer> 0012 #include <QMetaType> 0013 0014 class QImage; 0015 0016 namespace Kodaskanna 0017 { 0018 0019 namespace ImageSource 0020 { 0021 0022 class ImageReadResultPrivate; 0023 0024 class ImageReadResult 0025 { 0026 public: 0027 ImageReadResult(); 0028 ImageReadResult(const ImageReadResult &other); 0029 ~ImageReadResult(); 0030 0031 ImageReadResult &operator=(const ImageReadResult &other); 0032 0033 public: 0034 const QImage &image() const; 0035 bool isSuccess() const; 0036 0037 private: 0038 explicit ImageReadResult(ImageReadResultPrivate *dd); 0039 0040 private: 0041 friend class ReadImageFileRunner; 0042 QExplicitlySharedDataPointer<ImageReadResultPrivate> d; 0043 }; 0044 0045 } 0046 } 0047 0048 Q_DECLARE_METATYPE(Kodaskanna::ImageSource::ImageReadResult) 0049 0050 #endif