DBus-1-TQt 1.0
Loading...
Searching...
No Matches
tqdbusdatalist.h
Go to the documentation of this file.
1/* qdbusdatalist.h list of DBUS data transport type
2 *
3 * Copyright (C) 2007 Kevin Krammer <kevin.krammer@gmx.at>
4 *
5 * Licensed under the Academic Free License version 2.1
6 *
7 * This program is free software; you can redistribute it and/or modify
8 * it under the terms of the GNU General Public License as published by
9 * the Free Software Foundation; either version 2 of the License, or
10 * (at your option) any later version.
11 *
12 * This program is distributed in the hope that it will be useful,
13 * but WITHOUT ANY WARRANTY; without even the implied warranty of
14 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 * GNU General Public License for more details.
16 *
17 * You should have received a copy of the GNU General Public License
18 * along with this program; if not, write to the Free Software
19 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301,
20 * USA.
21 *
22 */
23
24#ifndef TQDBUSDATALIST_H
25#define TQDBUSDATALIST_H
26
27#include "tqdbusdata.h"
28
29template <typename T> class TQValueList;
31class TQT_DBusVariant;
32class TQT_DBusUnixFd;
33class TQString;
34class TQStringList;
35
72{
73public:
80
92 explicit TQT_DBusDataList(TQT_DBusData::Type simpleItemType);
93
104 explicit TQT_DBusDataList(const TQT_DBusData& containerItemType);
105
115
133
147
161
175
189
203
217
231
245
259
273
286 TQT_DBusDataList(const TQStringList& other);
287
301
315
320
331 TQT_DBusDataList& operator=(const TQT_DBusDataList& other);
332
347 TQT_DBusDataList& operator=(const TQValueList<TQT_DBusData>& other);
348
363 TQT_DBusDataList& operator=(const TQStringList& other);
364
373 TQT_DBusData::Type type() const;
374
388 bool hasContainerItemType() const;
389
405 TQT_DBusData containerItemType() const;
406
414 inline bool isValid() const { return type() != TQT_DBusData::Invalid; }
415
423 bool isEmpty() const;
424
432 uint count() const;
433
447 bool operator==(const TQT_DBusDataList& other) const;
448
462 bool operator!=(const TQT_DBusDataList& other) const;
463
469 void clear();
470
488 TQT_DBusDataList& operator<<(const TQT_DBusData& data);
489
495 TQValueList<TQT_DBusData> toTQValueList() const;
496
514 TQStringList toTQStringList(bool* ok = 0) const;
515
532 TQValueList<bool> toBoolList(bool* ok = 0) const;
533
550 TQValueList<TQ_UINT8> toByteList(bool* ok = 0) const;
551
569 TQValueList<TQ_INT16> toInt16List(bool* ok = 0) const;
570
588 TQValueList<TQ_UINT16> toUInt16List(bool* ok = 0) const;
589
607 TQValueList<TQ_INT32> toInt32List(bool* ok = 0) const;
608
626 TQValueList<TQ_UINT32> toUInt32List(bool* ok = 0) const;
627
645 TQValueList<TQ_INT64> toInt64List(bool* ok = 0) const;
646
664 TQValueList<TQ_UINT64> toUInt64List(bool* ok = 0) const;
665
682 TQValueList<double> toDoubleList(bool* ok = 0) const;
683
700 TQValueList<TQString> toStringList(bool* ok = 0) const;
701
715 TQValueList<TQT_DBusObjectPath> toObjectPathList(bool* ok = 0) const;
716
733 TQValueList<TQT_DBusVariant> toVariantList(bool* ok = 0) const;
734
751 TQValueList<TQT_DBusUnixFd> toUnixFdList(bool* ok = 0) const;
752
753private:
754 class Private;
756};
757
758#endif
Class for accurately representing D-Bus data types.
Definition tqdbusdata.h:59
Type
Enum for the data types used in D-Bus messages.
Definition tqdbusdata.h:74
Class to transport lists of D-Bus data types.
bool isValid() const
Checks whether this list object has a valid element type.
Class for representing D-Bus object paths.
Class for representing D-Bus unix file handles.
Data type for representing a D-Bus variant.
#define TQDBUS_EXPORT