76 marshaller->
ba = &signature;
86 bool ok = marshaller->
ok;
90 qWarning(
"QDBusMarshaller: type `%s' produces invalid D-BUS signature `%s' " 91 "(Did you forget to call beginStructure() ?)",
95 }
else if ((signature.
at(0) != DBUS_TYPE_ARRAY && signature.
at(0) != DBUS_STRUCT_BEGIN_CHAR) ||
96 (signature.
at(0) == DBUS_TYPE_ARRAY && (signature.
at(1) == DBUS_TYPE_BYTE ||
97 signature.
at(1) == DBUS_TYPE_STRING))) {
98 qWarning(
"QDBusMarshaller: type `%s' attempts to redefine basic D-BUS type '%s' (%s) " 99 "(Did you forget to call beginStructure() ?)",
129 qFatal(
"QDBusArgument: write from a read-only object");
131 qWarning(
"QDBusArgument: write from a read-only object");
144 qFatal(
"QDBusArgument: read from a write-only object");
146 qWarning(
"QDBusArgument: read from a write-only object");
310 dd->
message = q_dbus_message_new(DBUS_MESSAGE_TYPE_METHOD_CALL);
1238 #ifndef QDBUS_NO_SPECIALTYPES 1246 if (y != 0 && m != 0 && d != 0)
1268 a >> h >> m >> s >> ms;
1274 time.
setHMS(h, m, s, ms);
1284 a << -1 << -1 << -1 << -1;
1296 a >> date >> time >> timespec;
1313 int x, y, width, height;
1315 a >> x >> y >> width >> height;
1318 rect.
setRect(x, y, width, height);
1333 double x, y, width, height;
1335 a >> x >> y >> width >> height;
1345 a << double(rect.
x()) <<
double(rect.
y()) <<
double(rect.
width()) <<
double(rect.
height());
1371 double width, height;
1373 a >> width >> height;
1384 a << double(size.
width()) <<
double(size.
height());
1393 a >> pt.
rx() >> pt.
ry();
1402 a << pt.
x() << pt.
y();
1423 a << double(pt.
x()) <<
double(pt.
y());
1436 line =
QLine(p1, p2);
1443 a << line.
p1() << line.
p2();
1463 a << line.
p1() << line.
p2();
1472 #endif // QT_NO_DBUS The QVariant class acts like a union for the most common Qt data types.
void beginMapEntry()
Opens a D-Bus map entry suitable for appending the key and value entries.
static QDBusArgumentPrivate * d(QDBusArgument &q)
QDBusArgument::ElementType currentType()
qreal y() const
Returns the y-coordinate of the rectangle's top edge.
QDBusMarshaller * endArray()
void endArray()
Closes a D-Bus array opened with beginArray().
#define QT_END_NAMESPACE
This macro expands to.
QDBusDemarshaller * endStructure()
The QLine class provides a two-dimensional vector using integer precision.
bool isValid() const
Returns true if this date is valid; otherwise returns false.
QDBusArgument()
Constructs an empty QDBusArgument argument.
The QDBusArgument class is used to marshall and demarshall D-Bus arguments.
QPoint p1() const
Returns the line's start point.
QString currentSignature()
qreal width() const
Returns the width.
QPointF p1() const
Returns the line's start point.
QDBusDemarshaller * endMapEntry()
QDBusMarshaller * beginMapEntry()
QPoint p2() const
Returns the line's end point.
The QByteArray class provides an array of bytes.
void setY(qreal y)
Sets the y coordinate of this point to the given y coordinate.
The QPointF class defines a point in the plane using floating point precision.
qreal height() const
Returns the height.
int month() const
Returns the number corresponding to the month of this date, using the following convention: ...
QString currentSignature() const
Returns the type signature of the D-Bus type this QDBusArgument object is currently pointing to...
The QDBusSignature class enables the programmer to identify the SIGNATURE type provided by the D-Bus ...
int width() const
Returns the width of the rectangle.
void beginMap() const
Recurses into the D-Bus map to allow extraction of the map's elements.
int & ry()
Returns a reference to the y coordinate of this point.
int day() const
Returns the day of the month (1 to 31) of this date.
The QDate class provides date functions.
int msec() const
Returns the millisecond part (0 to 999) of the time.
long ASN1_INTEGER_get ASN1_INTEGER * a
bool ref()
Atomically increments the value of this QAtomicInt.
QDBusDemarshaller * beginMap()
int height() const
Returns the height of the rectangle.
QDBusDemarshaller * demarshaller()
The QString class provides a Unicode character string.
void setWidth(qreal w)
Sets the width to the given width.
static const char * typeToName(Type type)
Converts the enum representation of the storage type, typ, to its string representation.
The QSizeF class defines the size of a two-dimensional object using floating point precision...
QDBusDemarshaller * endArray()
bool appendVariantInternal(const QVariant &arg)
static bool checkReadAndDetach(QDBusArgumentPrivate *&d)
qreal x() const
Returns the x-coordinate of this point.
The QLineF class provides a two-dimensional vector using floating point precision.
The QDBusUnixFileDescriptor class holds one Unix file descriptor.
QDBusMarshaller * endStructure()
QDBusMarshaller * marshaller()
int width() const
Returns the width.
The QTime class provides clock time functions.
#define QT_BEGIN_NAMESPACE
This macro expands to.
The QRectF class defines a rectangle in the plane using floating point precision. ...
QDBusMarshaller * beginMap(int kid, int vid)
bool atEnd() const
Returns true if there are no more elements to be extracted from this QDBusArgument.
QStringList toStringList()
QDBusArgument & operator=(const QDBusArgument &other)
Copies the other QDBusArgument object into this one.
qreal height() const
Returns the height of the rectangle.
bool deref()
Atomically decrements the value of this QAtomicInt.
The QStringList class provides a list of strings.
Q_CORE_EXPORT void qWarning(const char *,...)
int & rx()
Returns a reference to the x coordinate of this point.
int second() const
Returns the second part (0 to 59) of the time.
Type
This enum type defines the types of variable that a QVariant can contain.
qreal width() const
Returns the width of the rectangle.
void setRect(qreal x, qreal y, qreal w, qreal h)
Sets the coordinates of the rectangle's top-left corner to (x, y), and its size to the given width an...
bool isValidSingleSignature(const QString &signature)
Returns true if signature is a valid D-Bus type signature for exactly one full type.
int minute() const
Returns the minute part (0 to 59) of the time.
QDBusDemarshaller * beginStructure()
static bool checkRead(QDBusArgumentPrivate *d)
QVariant asVariant() const
Returns the current argument in the form of a QVariant.
QDBusMarshaller * beginStructure()
QDBusSignature toSignature()
ElementType
This enum describes the type of element held by the argument.
const char * constData() const
Returns a pointer to the data stored in the byte array.
QDate date() const
Returns the date part of the datetime.
ElementType currentType() const
Returns the classification of the current element type.
Q_CORE_EXPORT void qFatal(const char *,...)
void endMapEntry()
Closes a D-Bus map entry opened with beginMapEntry().
int userType() const
Returns the storage type of the value stored in the variant.
void endMap()
Closes a D-Bus map opened with beginMap().
QDBusDemarshaller * endMap()
The QDateTime class provides date and time functions.
QDBusMarshaller * beginArray(int id)
static bool checkWrite(QDBusArgumentPrivate *&d)
int y() const
Returns the y-coordinate of the rectangle's top edge.
QDBusMarshaller * endMapEntry()
qreal x() const
Returns the x-coordinate of the rectangle's left edge.
QDBusArgument & operator<<(uchar arg)
Appends the primitive value arg of type BYTE to the D-Bus stream.
QVariant toVariantInternal()
static QString fromLatin1(const char *, int size=-1)
Returns a QString initialized with the first size characters of the Latin-1 string str...
void endStructure()
Closes a D-Bus structure opened with beginStructure().
int x() const
Returns the x-coordinate of the rectangle's left edge.
void setRect(int x, int y, int w, int h)
Sets the coordinates of the rectangle's top-left corner to ({x}, {y}), and its size to the given widt...
const void * constData() const
The QPoint class defines a point in the plane using integer precision.
Qt::TimeSpec timeSpec() const
Returns the time specification of the datetime.
The QDBusObjectPath class enables the programmer to identify the OBJECT_PATH type provided by the D-B...
int & rheight()
Returns a reference to the height.
void beginArray() const
Recurses into the D-Bus array to allow extraction of the array elements.
QPointF p2() const
Returns the line's end point.
int height() const
Returns the height.
The QRect class defines a rectangle in the plane using integer precision.
bool setYMD(int y, int m, int d)
Sets the date's year y, month m, and day d.
void qAtomicAssign(T *&d, T *x)
This is a helper for the assignment operators of implicitly shared classes.
QDBusUnixFileDescriptor toUnixFileDescriptor()
int y() const
Returns the y coordinate of this point.
void setX(qreal x)
Sets the x coordinate of this point to the given x coordinate.
qreal y() const
Returns the y-coordinate of this point.
void beginStructure()
Opens a new D-Bus structure suitable for appending new arguments.
void setHeight(qreal h)
Sets the height to the given height.
static QByteArray createSignature(int id)
int year() const
Returns the year of this date.
bool isEmpty() const
Returns true if the byte array has size 0; otherwise returns false.
The QSize class defines the size of a two-dimensional object using integer point precision.
QTime time() const
Returns the time part of the datetime.
QDBusObjectPath toObjectPath()
int x() const
Returns the x coordinate of this point.
QDBusMarshaller * endMap()
~QDBusArgument()
Disposes of the resources associated with this QDBusArgument object.
QDBusDemarshaller * beginArray()
enum QDBusArgumentPrivate::Direction direction
char at(int i) const
Returns the character at index position i in the byte array.
const QDBusArgument & operator>>(uchar &arg) const
Extracts one D-BUS primitive argument of type BYTE from the D-BUS stream and puts it into arg...
The QDBusVariant class enables the programmer to identify the variant type provided by the D-Bus type...
QString currentSignature()
bool setHMS(int h, int m, int s, int ms=0)
Sets the time to hour h, minute m, seconds s and milliseconds ms.
void appendVariant(const QVariant &v)
Appends the variant v.
int & rwidth()
Returns a reference to the width.
bool isValid() const
Returns true if the time is valid; otherwise returns false.
int hour() const
Returns the hour part (0 to 23) of the time.
QDBusDemarshaller * beginMapEntry()