Attica

listjob.cpp
1/*
2 This file is part of KDE.
3
4 SPDX-FileCopyrightText: 2009 Eckhart Wörner <ewoerner@kde.org>
5
6 SPDX-License-Identifier: LGPL-2.1-only OR LGPL-3.0-only OR LicenseRef-KDE-Accepted-LGPL
7*/
8
9#include "listjob.h"
10
11#include <QXmlStreamReader>
12#include <attica_debug.h>
13
14using namespace Attica;
15
16template<class T>
17ListJob<T>::ListJob(PlatformDependent *internals, const QNetworkRequest &request)
18 : GetJob(internals, request)
19{
20 qCDebug(ATTICA) << "creating list job:" << request.url();
21}
22
23template<class T>
24typename T::List ListJob<T>::itemList() const
25{
26 return m_itemList;
27}
28
29template<class T>
30void ListJob<T>::parse(const QString &xml)
31{
32 typename T::Parser parser;
33 m_itemList = parser.parseList(xml);
34 setMetadata(parser.metadata());
35 qCDebug(ATTICA) << "received categories:" << m_itemList.size();
36}
Represents a get job.
Definition getjob.h:26
Represents a list job.
Definition listjob.h:28
The Attica namespace,.
QUrl url() const const
This file is part of the KDE documentation.
Documentation copyright © 1996-2024 The KDE developers.
Generated on Mon Nov 18 2024 12:17:36 by doxygen 1.12.0 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.