From 0e52fd954977d63f1280d61c9f0c3e3232e55be9 Mon Sep 17 00:00:00 2001 From: Linus Jahn Date: Sat, 27 Mar 2021 14:32:53 +0100 Subject: BitsBinaryDataList: Merge into QXmppBitsOfBinaryData compilation unit This should speed up compilation a bit. --- src/base/QXmppBitsOfBinaryDataList.cpp | 67 ---------------------------------- 1 file changed, 67 deletions(-) delete mode 100644 src/base/QXmppBitsOfBinaryDataList.cpp (limited to 'src/base/QXmppBitsOfBinaryDataList.cpp') diff --git a/src/base/QXmppBitsOfBinaryDataList.cpp b/src/base/QXmppBitsOfBinaryDataList.cpp deleted file mode 100644 index fda17ff7..00000000 --- a/src/base/QXmppBitsOfBinaryDataList.cpp +++ /dev/null @@ -1,67 +0,0 @@ -/* - * Copyright (C) 2008-2021 The QXmpp developers - * - * Author: - * Linus Jahn - * - * Source: - * https://github.com/qxmpp-project/qxmpp - * - * This file is a part of QXmpp library. - * - * This library is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 2.1 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - */ - -#include "QXmppBitsOfBinaryDataList.h" - -#include "QXmppBitsOfBinaryData.h" -#include "QXmppConstants_p.h" - -#include - -/// -/// \class QXmppBitsOfBinaryDataList -/// -/// QXmppBitsOfBinaryDataList represents a list of data elements from -/// \xep{0231, Bits of Binary}. -/// -/// \since QXmpp 1.2 -/// - -QXmppBitsOfBinaryDataList::QXmppBitsOfBinaryDataList() = default; - -QXmppBitsOfBinaryDataList::~QXmppBitsOfBinaryDataList() = default; - -/// \cond -void QXmppBitsOfBinaryDataList::parse(const QDomElement &element) -{ - // clear previous data elements - clear(); - - // parse all elements - QDomElement child = element.firstChildElement(); - while (!child.isNull()) { - if (QXmppBitsOfBinaryData::isBitsOfBinaryData(child)) { - QXmppBitsOfBinaryData data; - data.parseElementFromChild(child); - append(data); - } - child = child.nextSiblingElement(); - } -} - -void QXmppBitsOfBinaryDataList::toXml(QXmlStreamWriter *writer) const -{ - for (const auto &bitsOfBinaryData : *this) - bitsOfBinaryData.toXmlElementFromChild(writer); -} -/// \endcond -- cgit v1.2.3