15#ifndef QGSNEWSFEEDPARSER_H
16#define QGSNEWSFEEDPARSER_H
110 QList< QgsNewsFeedParser::Entry > entries()
const;
119 void dismissEntry(
int key );
130 QString authcfg()
const;
135 static QString keyForFeed(
const QString &baseUrl );
152 void fetched(
const QList< QgsNewsFeedParser::Entry > &entries );
178 void onFetch(
const QString &content );
185 qint64 mFetchStartTime = 0;
188 QList< Entry > mEntries;
189 bool mBlockSignals =
false;
191 void readStoredEntries();
192 Entry readEntryFromSettings(
int key );
193 void storeEntryInSettings(
const Entry &entry );
194 void fetchImageForEntry(
const Entry &entry );
196 friend class TestQgsNewsFeedParser;
HTTP network content fetcher.
Represents a single entry from a news feed.
QString content
HTML content of news entry.
QUrl link
Optional URL link for entry.
QString imageUrl
Optional URL for image associated with entry.
QPixmap image
Optional image data.
QDateTime expiry
Optional auto-expiry time for entry.
QString title
Entry title.
Parser for published QGIS news feeds.
void entryDismissed(const QgsNewsFeedParser::Entry &entry)
Emitted whenever an entry is dismissed (as a result of a call to dismissEntry()).
static const QgsSettingsEntryString * settingsFeedEntryTitle
static const QgsSettingsEntryString * settingsFeedEntryLink
void fetched(const QList< QgsNewsFeedParser::Entry > &entries)
Emitted when entries have fetched from the feed.
static const QgsSettingsEntryString * settingsFeedEntryImageUrl
static const QgsSettingsEntryDouble * settingsFeedLatitude
static const QgsSettingsEntryInteger64 * settingsFeedLastFetchTime
static const QgsSettingsEntryBool * settingsFeedEntrySticky
static const QgsSettingsEntryDouble * settingsFeedLongitude
static const QgsSettingsEntryString * settingsFeedLanguage
static const QgsSettingsEntryString * settingsFeedEntryContent
static const QgsSettingsEntryVariant * settingsFeedEntryExpiry
void entryAdded(const QgsNewsFeedParser::Entry &entry)
Emitted whenever a new entry is available from the feed (as a result of a call to fetch()).
void imageFetched(int key, const QPixmap &pixmap)
Emitted when the image attached to the entry with the specified key has been fetched and is now avail...
A boolean settings entry.
A 64 bits integer (long long) settings entry.
A variant settings entry.
QgsSettingsTreeNamedListNode is a named list tree node for the settings tree to help organizing and i...
QgsSettingsTreeNamedListNode * createNamedListNode(const QString &key, const Qgis::SettingsTreeNodeOptions &options=Qgis::SettingsTreeNodeOptions()) SIP_THROW(QgsSettingsException)
Creates a named list tree node.
static QgsSettingsTreeNode * sTreeApp