summaryrefslogtreecommitdiffstats
path: root/doc
diff options
context:
space:
mode:
authorAlexander Larsson <alexl@redhat.com>2003-04-08 15:52:51 +0000
committerAlexander Larsson <alexl@redhat.com>2003-04-08 15:52:51 +0000
commitc5020ac870c5990a36c3576453cc23431213e8bf (patch)
tree8b5c4c5b884e9481d1ce17b9a24d9c1bbe094428 /doc
parenta162febe6746269f51b3a16db5f6fb240001f828 (diff)
2003-04-08 Alexander Larsson <alexl@redhat.com>
Implemented recursive types, named types and new-style iters * bus/driver.c: * glib/test-thread-client.c: (thread_func): * glib/test-thread-server.c: (handle_test_message): * test/test-service.c: (handle_echo): Update to new api * dbus/Makefile.am: * dbus/dbus-dict.c: * dbus/dbus-dict.h: * dbus/dbus.h Remove DBusDict * dbus/dbus-internals.c: (_dbus_type_to_string): Update for new types. * dbus/dbus-marshal.[ch]: Implement recursive types and the new marshalling format. Remove hardcoded dict marshalling. Marshal named types. * dbus/dbus-message-builder.c: Add BYTE_ARRAY. Remove references to old types * dbus/dbus-message.[ch]: New non-refcounted iter API that supports recursive iters. Use iters for appending, including support for recursive iters. Add byte and named type support. Update everything to new marshalling formats. Add tests for new API. * dbus/dbus-protocol.h: Remove old array types. Add types: BYTE, ARRAY, DICT, NAMED * dbus/dbus-string.c: * dbus/dbus-sysdeps.c: Make parse_double locale safe. * dbus/dbus-test-main.c: Call setlocale. * dbus/dbus-test.c: Kill dict test * doc/dbus-specification.sgml: Update spec * test/data/incomplete-messages/missing-body.message: * test/data/invalid-messages/bad-boolean.message: * test/data/invalid-messages/bad-boolean-array.message: * test/data/invalid-messages/boolean-array-length-too-long.message-raw: * test/data/invalid-messages/boolean-has-no-value.message-raw: * test/data/invalid-messages/too-short-dict.message: * test/data/valid-messages/dict-simple.message: * test/data/valid-messages/dict.message: * test/data/valid-messages/emptiness.message: * test/data/valid-messages/lots-of-arguments.message: * test/data/valid-messages/no-padding.message: * test/data/valid-messages/recursive-types.message: Add missing NAME fields Fix up dicts & arrays * test/data/invalid-messages/dict-with-nil-value.message: Removed, this is not invalid anymore. * test/data/valid-messages/recursive-types.message: Add new test for deeply recursive types.
Diffstat (limited to 'doc')
-rw-r--r--doc/dbus-specification.sgml89
1 files changed, 39 insertions, 50 deletions
diff --git a/doc/dbus-specification.sgml b/doc/dbus-specification.sgml
index 3bd49ac4..200ef430 100644
--- a/doc/dbus-specification.sgml
+++ b/doc/dbus-specification.sgml
@@ -305,49 +305,41 @@
<entry>1</entry>
<entry>Marks an "unset" or "nonexistent" argument</entry>
</row><row>
- <entry>BOOLEAN</entry>
+ <entry>BYTE</entry>
<entry>2</entry>
+ <entry>8-bit unsigned integer.</entry>
+ </row><row>
+ <entry>BOOLEAN</entry>
+ <entry>3</entry>
<entry>Boolean value, 0 is FALSE and 1 is TRUE. Everything else is invalid.</entry>
</row><row>
<entry>INT32</entry>
- <entry>3</entry>
+ <entry>4</entry>
<entry>32-bit signed integer</entry>
</row><row>
<entry>UINT32</entry>
- <entry>4</entry>
+ <entry>5</entry>
<entry>32-bit unsigned integer</entry>
</row><row>
<entry>DOUBLE</entry>
- <entry>5</entry>
+ <entry>6</entry>
<entry>IEEE 754 double</entry>
</row><row>
<entry>STRING</entry>
- <entry>6</entry>
- <entry>UTF-8 string (<emphasis>must</emphasis> be valid UTF-8)</entry>
- </row><row>
- <entry>BOOLEAN_ARRAY</entry>
- <entry>7</entry>
- <entry>Array of BOOLEAN</entry>
- </row><row>
- <entry>INT32_ARRAY</entry>
- <entry>6</entry>
- <entry>Array of INT32</entry>
- </row><row>
- <entry>UINT32_ARRAY</entry>
<entry>7</entry>
- <entry>Array of UINT32</entry>
- </row><row>
- <entry>DOUBLE_ARRAY</entry>
- <entry>8</entry>
- <entry>Array of DOUBLE</entry>
+ <entry>UTF-8 string (<emphasis>must</emphasis> be valid UTF-8). Must be zero terminated. </entry>
</row><row>
- <entry>BYTE_ARRAY</entry>
+ <entry>NAMED</entry>
+ <entry>8</entry>
+ <entry>A named byte array, used for custom types</entry>
+ </row><row>
+ <entry>ARRAY</entry>
<entry>9</entry>
- <entry>Array of bytes</entry>
+ <entry>Array</entry>
</row><row>
- <entry>STRING_ARRAY</entry>
+ <entry>DICT</entry>
<entry>10</entry>
- <entry>Array of STRING</entry>
+ <entry>A dictionary of key/value pairs</entry>
</row>
</tbody>
</tgroup>
@@ -372,6 +364,12 @@
<entry>No data is encoded; the type code is followed immediately
by the type code of the next argument.</entry>
</row><row>
+ <entry>BYTE</entry>
+ <entry>a byte.</entry>
+ </row><row>
+ <entry>BOOLEAN</entry>
+ <entry>a byte, with valid values 0 and 1.</entry>
+ </row><row>
<entry>INT32</entry>
<entry>32-bit signed integer in the message's byte order, aligned to 4-byte boundary.</entry>
</row><row>
@@ -388,35 +386,26 @@
byte.
</entry>
</row><row>
- <entry>INT32_ARRAY</entry>
- <entry>UINT32 giving the number of values in the array,
- followed by the given number of INT32 values.
- </entry>
- </row><row>
- <entry>UINT32_ARRAY</entry>
- <entry>UINT32 giving the number of values in the array,
- followed by the given number of UINT32 values.
- </entry>
- </row><row>
- <entry>DOUBLE_ARRAY</entry>
- <entry>UINT32 giving the number of values in the array,
- followed by the given number of DOUBLE values aligned
- to 8-byte boundary.
- </entry>
- </row><row>
- <entry>BYTE_ARRAY</entry>
- <entry>UINT32 giving the number of values in the array,
- followed by the given number of one-byte values.
+ <entry>NAMED</entry>
+ <entry>A string (encoded as the STRING type above) giving the
+ name of the type followed by an UINT32 aligned to 4-byte boundary
+ indicating the data length in bytes, followed by the data.
</entry>
</row><row>
- <entry>STRING_ARRAY</entry>
- <entry>UINT32 giving the number of values in the array,
- followed by the given number of STRING values.
+ <entry>ARRAY</entry>
+ <entry>a byte giving the element type of the array followed
+ by an UINT32 (aligned to 4 bytes) giving the length of the
+ array data in bytes. This is then followed by a number of
+ entires with the same type, encoded like that type normally
+ would be encoded alone.
</entry>
</row><row>
- <entry>DICT</entry>
- <entry>STRING_ARRAY with the keys, followed by the given
- number of values encoded as type code as a byte followed by the encoded value.
+ <entry>DICT</entry>
+ <entry>UINT32 giving the length of the dictionary data in bytes.
+ This is followed by a number of keyname/value pairs, where the
+ keyname is encoded as a STRING above, and the value is encoded
+ as a byte with typecode and how that type normally would be encoded
+ alone.
</entry>
</row>
</tbody>