File indexing completed on 2025-01-05 05:14:39

0001 /*
0002 SPDX-FileCopyrightText: 2021 Hamed Masafi <hamed.masfi@gmail.com>
0003 
0004 SPDX-License-Identifier: GPL-3.0-or-later
0005 */
0006 
0007 #pragma once
0008 
0009 #include <QMap>
0010 #include <QNetworkAccessManager>
0011 #include <QString>
0012 
0013 class GravatarCache : public QObject
0014 {
0015     Q_OBJECT
0016 
0017 public:
0018     GravatarCache(QObject *parent = nullptr);
0019     QString avatarPath(const QString &email);
0020 
0021 private:
0022     QNetworkAccessManager mNet;
0023     QMap<QString, QString> mAvatarsCache;
0024 };