LeechCraft 0.6.70-17609-g3dde4097dd
Modular cross-platform feature rich live environment.
Loading...
Searching...
No Matches
asdomdocument.cpp
Go to the documentation of this file.
1/**********************************************************************
2 * LeechCraft - modular cross-platform feature rich internet client.
3 * Copyright (C) 2006-2014 Georg Rudoy
4 *
5 * Distributed under the Boost Software License, Version 1.0.
6 * (See accompanying file LICENSE or copy at https://www.boost.org/LICENSE_1_0.txt)
7 **********************************************************************/
8
9#include "asdomdocument.h"
10#include <QtDebug>
11
12namespace LC::Util
13{
14 AsDomDocument::AsDomDocument (const QByteArray& data, const QString& errorMessage, const std::source_location& loc)
15 : ErrorMessage_ { errorMessage }
16 {
17 if (!Doc_.setContent (data))
18 qWarning () << loc.file_name () << ":" << loc.line () << ":" << loc.function_name () << "failed to parse" << data;
19 }
20
22 {
23 return !Doc_.isNull ();
24 }
25
26 QDomDocument AsDomDocument::await_resume () const
27 {
28 return Doc_;
29 }
30}
AsDomDocument(const QByteArray &data, const QString &errorMessage, const std::source_location &loc=std::source_location::current())
QDomDocument await_resume() const