2
* Copyright (C) 2015 Canonical Ltd
4
* This program is free software: you can redistribute it and/or modify
5
* it under the terms of the GNU Lesser General Public License version 3 as
6
* published by the Free Software Foundation.
8
* This program is distributed in the hope that it will be useful,
9
* but WITHOUT ANY WARRANTY; without even the implied warranty of
10
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11
* GNU Lesser General Public License for more details.
13
* You should have received a copy of the GNU Lesser General Public License
14
* along with this program. If not, see <http://www.gnu.org/licenses/>.
16
* Authored by: Xavi Garcia <xavi.garcia.mena@canonical.com>
19
#include <unity/scopes/qt/QVariantBuilder.h>
21
#include <unity/scopes/qt/internal/QVariantBuilderImpl.h>
23
#include <unity/scopes/VariantBuilder.h>
25
using namespace unity::scopes::qt;
27
QVariantBuilder::QVariantBuilder()
28
: p(new internal::QVariantBuilderImpl())
32
QVariantBuilder::~QVariantBuilder() = default;
34
QVariantBuilder::QVariantBuilder(QVariantBuilder const& other)
35
: p(new internal::QVariantBuilderImpl(*other.p))
39
QVariantBuilder::QVariantBuilder(QVariantBuilder&&) = default;
41
QVariantBuilder& QVariantBuilder::operator=(QVariantBuilder const& other)
45
p.reset(new internal::QVariantBuilderImpl(*other.p));
51
QVariantBuilder& QVariantBuilder::operator=(QVariantBuilder&& other) = default;
54
void QVariantBuilder::add_tuple(QVector<QPair<QString, QVariant>> const& tuple)
59
QVariant QVariantBuilder::end()