~timo-jyrinki/ubuntu/trusty/maliit-framework/fix_qt52

« back to all changes in this revision

Viewing changes to connection/variantmarshalling.h

  • Committer: Package Import Robot
  • Author(s): Ricardo Salveti de Araujo
  • Date: 2013-07-23 19:47:04 UTC
  • mto: This revision was merged to the branch mainline in revision 8.
  • Revision ID: package-import@ubuntu.com-20130723194704-0o18p2ao0x9sa1zx
Tags: upstream-0.99.0+git20130615+97e8335
ImportĀ upstreamĀ versionĀ 0.99.0+git20130615+97e8335

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
/* * This file is part of Maliit framework *
2
 
 *
3
 
 * Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies).
4
 
 * All rights reserved.
5
 
 *
6
 
 * Contact: maliit-discuss@lists.maliit.org
7
 
 *
8
 
 * This library is free software; you can redistribute it and/or
9
 
 * modify it under the terms of the GNU Lesser General Public
10
 
 * License version 2.1 as published by the Free Software Foundation
11
 
 * and appearing in the file LICENSE.LGPL included in the packaging
12
 
 * of this file.
13
 
 */
14
 
 
15
 
#ifndef VARIANTMARSHALLING_H
16
 
#define VARIANTMARSHALLING_H
17
 
 
18
 
#include <glib.h>
19
 
#include <dbus/dbus-glib-lowlevel.h>
20
 
#include <dbus/dbus-glib.h>
21
 
 
22
 
#include <QVariant>
23
 
 
24
 
 
25
 
/*!
26
 
 * \brief Convert data from GValue into QVariant.
27
 
 * \param[out] dest Variable to get result to.
28
 
 * \param[in] source Original value.
29
 
 * \param[out] error_message Contains error description if original value could not be decoded.
30
 
 */
31
 
bool decodeVariant(QVariant *dest, GValue *source, QString *error_message);
32
 
 
33
 
 
34
 
/*!
35
 
 * \brief Convert data from GHashTable into QVariantMap.
36
 
 * \param[out] dest Variable to get result to.
37
 
 * \param[in] source Original value.
38
 
 * \param[out] error_message Contains error description if original value could not be decoded.
39
 
 */
40
 
bool decodeVariantMap(QVariantMap *dest, GHashTable *source, QString *error_message);
41
 
 
42
 
 
43
 
/*!
44
 
 * \brief Convert data from QVariant into GValue.
45
 
 * \param[out] dest Variable to get result to.
46
 
 * \param[in] source Original value.
47
 
 */
48
 
bool encodeVariant(GValue *dest, const QVariant &source);
49
 
 
50
 
 
51
 
/*!
52
 
 * \brief Convert data from QVariantMap into GHashTable.
53
 
 * \param[in] source Original value.
54
 
 * \return a newly-allocated hash table, or 0 on failure
55
 
 */
56
 
GHashTable *encodeVariantMap(const QVariantMap &source);
57
 
 
58
 
#endif