delete some more noise, put args in consistent order (a big bug trap sadly),
[platform/upstream/dbus.git] / dbus / dbus-marshal-recursive.h
index 019daac..064bf15 100644 (file)
@@ -46,6 +46,8 @@
  *  - implement has_next()
  *  - the all-in-one-block array accessors
  *  - validation
+ *
+ * - remember to try a HAVE_INT64=0 build at the end
  */
 
 typedef struct DBusTypeMark        DBusTypeMark;
@@ -54,7 +56,12 @@ typedef struct DBusTypeWriter      DBusTypeWriter;
 typedef struct DBusTypeReaderClass DBusTypeReaderClass;
 
 /* The mark is a way to compress a TypeReader; it isn't all that
- * successful though.
+ * successful though. The idea was to use this for caching header
+ * fields in dbus-message.c. However now I'm thinking why not cache
+ * the actual values (e.g. char*) and if the field needs to be set or
+ * deleted, just linear search for it. Those operations are uncommon,
+ * and getting the values should be fast and not involve all this type
+ * reader nonsense.
  */
 struct DBusTypeMark
 {
@@ -141,33 +148,34 @@ void        _dbus_type_reader_recurse                   (DBusTypeReader        *
                                                          DBusTypeReader        *subreader);
 dbus_bool_t _dbus_type_reader_next                      (DBusTypeReader        *reader);
 dbus_bool_t _dbus_type_reader_has_next                  (const DBusTypeReader  *reader);
-
-
-void        _dbus_type_writer_init            (DBusTypeWriter *writer,
-                                               int             byte_order,
-                                               DBusString     *type_str,
-                                               int             type_pos,
-                                               DBusString     *value_str,
-                                               int             value_pos);
-dbus_bool_t _dbus_type_writer_write_basic     (DBusTypeWriter *writer,
-                                               int             type,
-                                               const void     *value);
-dbus_bool_t _dbus_type_writer_write_array     (DBusTypeWriter *writer,
-                                               int             type,
-                                               const void     *array,
-                                               int             array_len);
-dbus_bool_t _dbus_type_writer_recurse_struct  (DBusTypeWriter *writer,
-                                               DBusTypeWriter *sub);
-dbus_bool_t _dbus_type_writer_recurse_array   (DBusTypeWriter *writer,
-                                               const char     *element_type,
-                                               DBusTypeWriter *sub);
-dbus_bool_t _dbus_type_writer_recurse_variant (DBusTypeWriter *writer,
-                                               const char     *contained_type,
-                                               DBusTypeWriter *sub);
-dbus_bool_t _dbus_type_writer_unrecurse       (DBusTypeWriter *writer,
-                                               DBusTypeWriter *sub);
-dbus_bool_t _dbus_type_writer_write_reader    (DBusTypeWriter *writer,
-                                               DBusTypeReader *reader);
-
+void        _dbus_type_reader_get_signature             (const DBusTypeReader  *reader,
+                                                         const DBusString     **str_p,
+                                                         int                   *start_p,
+                                                         int                   *len_p);
+dbus_bool_t _dbus_type_reader_set_basic                 (DBusTypeReader        *reader,
+                                                         const void            *value);
+
+void        _dbus_type_writer_init         (DBusTypeWriter   *writer,
+                                            int               byte_order,
+                                            DBusString       *type_str,
+                                            int               type_pos,
+                                            DBusString       *value_str,
+                                            int               value_pos);
+dbus_bool_t _dbus_type_writer_write_basic  (DBusTypeWriter   *writer,
+                                            int               type,
+                                            const void       *value);
+dbus_bool_t _dbus_type_writer_write_array  (DBusTypeWriter   *writer,
+                                            int               type,
+                                            const void       *array,
+                                            int               array_len);
+dbus_bool_t _dbus_type_writer_recurse      (DBusTypeWriter   *writer,
+                                            int               container_type,
+                                            const DBusString *contained_type,
+                                            int               contained_type_start,
+                                            DBusTypeWriter   *sub);
+dbus_bool_t _dbus_type_writer_unrecurse    (DBusTypeWriter   *writer,
+                                            DBusTypeWriter   *sub);
+dbus_bool_t _dbus_type_writer_write_reader (DBusTypeWriter   *writer,
+                                            DBusTypeReader   *reader);
 
 #endif /* DBUS_MARSHAL_RECURSIVE_H */