gvariant.h   gvariant.h 
skipping to change at line 23 skipping to change at line 23
* Lesser General Public License for more details. * Lesser General Public License for more details.
* *
* You should have received a copy of the GNU Lesser General Public * You should have received a copy of the GNU Lesser General Public
* License along with this library; if not, write to the * License along with this library; if not, write to the
* Free Software Foundation, Inc., 59 Temple Place - Suite 330, * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
* Boston, MA 02111-1307, USA. * Boston, MA 02111-1307, USA.
* *
* Author: Ryan Lortie <desrt@desrt.ca> * Author: Ryan Lortie <desrt@desrt.ca>
*/ */
#if defined(G_DISABLE_SINGLE_INCLUDES) && !defined (__GLIB_H_INSIDE__) && !
defined (GLIB_COMPILATION)
#error "Only <glib.h> can be included directly."
#endif
#ifndef __G_VARIANT_H__ #ifndef __G_VARIANT_H__
#define __G_VARIANT_H__ #define __G_VARIANT_H__
#include <glib/gvarianttype.h> #include <glib/gvarianttype.h>
#include <glib/gstring.h> #include <glib/gstring.h>
G_BEGIN_DECLS G_BEGIN_DECLS
typedef struct _GVariant GVariant; typedef struct _GVariant GVariant;
skipping to change at line 58 skipping to change at line 62
G_VARIANT_CLASS_VARIANT = 'v', G_VARIANT_CLASS_VARIANT = 'v',
G_VARIANT_CLASS_MAYBE = 'm', G_VARIANT_CLASS_MAYBE = 'm',
G_VARIANT_CLASS_ARRAY = 'a', G_VARIANT_CLASS_ARRAY = 'a',
G_VARIANT_CLASS_TUPLE = '(', G_VARIANT_CLASS_TUPLE = '(',
G_VARIANT_CLASS_DICT_ENTRY = '{' G_VARIANT_CLASS_DICT_ENTRY = '{'
} GVariantClass; } GVariantClass;
void g_variant_unref (GV ariant *value); void g_variant_unref (GV ariant *value);
GVariant * g_variant_ref (GV ariant *value); GVariant * g_variant_ref (GV ariant *value);
GVariant * g_variant_ref_sink (GV ariant *value); GVariant * g_variant_ref_sink (GV ariant *value);
gboolean g_variant_is_floating (GV ariant *value);
const GVariantType * g_variant_get_type (GV ariant *value); const GVariantType * g_variant_get_type (GV ariant *value);
const gchar * g_variant_get_type_string (GV ariant *value); const gchar * g_variant_get_type_string (GV ariant *value);
gboolean g_variant_is_of_type (GV ariant *value, gboolean g_variant_is_of_type (GV ariant *value,
co nst GVariantType *type); co nst GVariantType *type);
gboolean g_variant_is_container (GV ariant *value); gboolean g_variant_is_container (GV ariant *value);
GVariantClass g_variant_classify (GV ariant *value); GVariantClass g_variant_classify (GV ariant *value);
GVariant * g_variant_new_boolean (gb
GVariant * g_variant_new_boolean (gb oolean value);
oolean boolean); GVariant * g_variant_new_byte (gu
GVariant * g_variant_new_byte (gu char value);
char byte); GVariant * g_variant_new_int16 (gi
GVariant * g_variant_new_int16 (gi nt16 value);
nt16 int16); GVariant * g_variant_new_uint16 (gu
GVariant * g_variant_new_uint16 (gu int16 value);
int16 uint16); GVariant * g_variant_new_int32 (gi
GVariant * g_variant_new_int32 (gi nt32 value);
nt32 int32); GVariant * g_variant_new_uint32 (gu
GVariant * g_variant_new_uint32 (gu int32 value);
int32 uint32); GVariant * g_variant_new_int64 (gi
GVariant * g_variant_new_int64 (gi nt64 value);
nt64 int64); GVariant * g_variant_new_uint64 (gu
GVariant * g_variant_new_uint64 (gu int64 value);
int64 uint64); GVariant * g_variant_new_handle (gi
GVariant * g_variant_new_handle (gi nt32 value);
nt32 handle); GVariant * g_variant_new_double (gd
GVariant * g_variant_new_double (gd ouble value);
ouble floating);
GVariant * g_variant_new_string (co nst gchar *string); GVariant * g_variant_new_string (co nst gchar *string);
GVariant * g_variant_new_object_path (co nst gchar *object_path); GVariant * g_variant_new_object_path (co nst gchar *object_path);
gboolean g_variant_is_object_path (co nst gchar *string); gboolean g_variant_is_object_path (co nst gchar *string);
GVariant * g_variant_new_signature (co nst gchar *signature); GVariant * g_variant_new_signature (co nst gchar *signature);
gboolean g_variant_is_signature (co nst gchar *string); gboolean g_variant_is_signature (co nst gchar *string);
GVariant * g_variant_new_variant (GV ariant *value); GVariant * g_variant_new_variant (GV ariant *value);
GVariant * g_variant_new_strv (co nst gchar * const *strv, GVariant * g_variant_new_strv (co nst gchar * const *strv,
gs size length); gs size length);
GVariant * g_variant_new_bytestring (co
nst gchar *string);
GVariant * g_variant_new_bytestring_array (co
nst gchar * const *strv,
gs
size length);
gboolean g_variant_get_boolean (GV ariant *value); gboolean g_variant_get_boolean (GV ariant *value);
guchar g_variant_get_byte (GV ariant *value); guchar g_variant_get_byte (GV ariant *value);
gint16 g_variant_get_int16 (GV ariant *value); gint16 g_variant_get_int16 (GV ariant *value);
guint16 g_variant_get_uint16 (GV ariant *value); guint16 g_variant_get_uint16 (GV ariant *value);
gint32 g_variant_get_int32 (GV ariant *value); gint32 g_variant_get_int32 (GV ariant *value);
guint32 g_variant_get_uint32 (GV ariant *value); guint32 g_variant_get_uint32 (GV ariant *value);
gint64 g_variant_get_int64 (GV ariant *value); gint64 g_variant_get_int64 (GV ariant *value);
guint64 g_variant_get_uint64 (GV ariant *value); guint64 g_variant_get_uint64 (GV ariant *value);
gint32 g_variant_get_handle (GV ariant *value); gint32 g_variant_get_handle (GV ariant *value);
gdouble g_variant_get_double (GV ariant *value); gdouble g_variant_get_double (GV ariant *value);
GVariant * g_variant_get_variant (GV ariant *value); GVariant * g_variant_get_variant (GV ariant *value);
const gchar * g_variant_get_string (GV ariant *value, const gchar * g_variant_get_string (GV ariant *value,
gs ize *length); gs ize *length);
gchar * g_variant_dup_string (GV ariant *value, gchar * g_variant_dup_string (GV ariant *value,
gs ize *length); gs ize *length);
const gchar ** g_variant_get_strv (GV ariant *value, const gchar ** g_variant_get_strv (GV ariant *value,
gs ize *length); gs ize *length);
gchar ** g_variant_dup_strv (GV ariant *value, gchar ** g_variant_dup_strv (GV ariant *value,
gs ize *length); gs ize *length);
const gchar * g_variant_get_bytestring (GV
ariant *value);
gchar * g_variant_dup_bytestring (GV
ariant *value,
gs
ize *length);
const gchar ** g_variant_get_bytestring_array (GV
ariant *value,
gs
ize *length);
gchar ** g_variant_dup_bytestring_array (GV
ariant *value,
gs
ize *length);
GVariant * g_variant_new_maybe (co nst GVariantType *child_type, GVariant * g_variant_new_maybe (co nst GVariantType *child_type,
GV ariant *child); GV ariant *child);
GVariant * g_variant_new_array (co nst GVariantType *child_type, GVariant * g_variant_new_array (co nst GVariantType *child_type,
GV ariant * const *children, GV ariant * const *children,
gs ize n_children); gs ize n_children);
GVariant * g_variant_new_tuple (GV ariant * const *children, GVariant * g_variant_new_tuple (GV ariant * const *children,
gs ize n_children); gs ize n_children);
GVariant * g_variant_new_dict_entry (GV ariant *key, GVariant * g_variant_new_dict_entry (GV ariant *key,
GV ariant *value); GV ariant *value);
GVariant * g_variant_get_maybe (GV ariant *value); GVariant * g_variant_get_maybe (GV ariant *value);
gsize g_variant_n_children (GV ariant *value); gsize g_variant_n_children (GV ariant *value);
void g_variant_get_child (GV ariant *value, void g_variant_get_child (GV ariant *value,
gs ize index_, gs ize index_,
co nst gchar *format_string, co nst gchar *format_string,
.. .); .. .);
GVariant * g_variant_get_child_value (GV ariant *value, GVariant * g_variant_get_child_value (GV ariant *value,
gs ize index_); gs ize index_);
gboolean g_variant_lookup (GV
ariant *dictionary,
co
nst gchar *key,
co
nst gchar *format_string,
..
.);
GVariant * g_variant_lookup_value (GV
ariant *dictionary,
co
nst gchar *key,
co
nst GVariantType *expected_type);
gconstpointer g_variant_get_fixed_array (GV ariant *value, gconstpointer g_variant_get_fixed_array (GV ariant *value,
gs ize *n_elements, gs ize *n_elements,
gs ize element_size); gs ize element_size);
gsize g_variant_get_size (GV ariant *value); gsize g_variant_get_size (GV ariant *value);
gconstpointer g_variant_get_data (GV ariant *value); gconstpointer g_variant_get_data (GV ariant *value);
void g_variant_store (GV ariant *value, void g_variant_store (GV ariant *value,
gp ointer data); gp ointer data);
gchar * g_variant_print (GV ariant *value, gchar * g_variant_print (GV ariant *value,
skipping to change at line 178 skipping to change at line 199
gboolean g_variant_iter_loop (GV ariantIter *iter, gboolean g_variant_iter_loop (GV ariantIter *iter,
co nst gchar *format_string, co nst gchar *format_string,
.. .); .. .);
typedef struct _GVariantBuilder GVariantBuilder; typedef struct _GVariantBuilder GVariantBuilder;
struct _GVariantBuilder { struct _GVariantBuilder {
/*< private >*/ /*< private >*/
gsize x[16]; gsize x[16];
}; };
typedef enum
{
G_VARIANT_PARSE_ERROR_FAILED,
G_VARIANT_PARSE_ERROR_BASIC_TYPE_EXPECTED,
G_VARIANT_PARSE_ERROR_CANNOT_INFER_TYPE,
G_VARIANT_PARSE_ERROR_DEFINITE_TYPE_EXPECTED,
G_VARIANT_PARSE_ERROR_INPUT_NOT_AT_END,
G_VARIANT_PARSE_ERROR_INVALID_CHARACTER,
G_VARIANT_PARSE_ERROR_INVALID_FORMAT_STRING,
G_VARIANT_PARSE_ERROR_INVALID_OBJECT_PATH,
G_VARIANT_PARSE_ERROR_INVALID_SIGNATURE,
G_VARIANT_PARSE_ERROR_INVALID_TYPE_STRING,
G_VARIANT_PARSE_ERROR_NO_COMMON_TYPE,
G_VARIANT_PARSE_ERROR_NUMBER_OUT_OF_RANGE,
G_VARIANT_PARSE_ERROR_NUMBER_TOO_BIG,
G_VARIANT_PARSE_ERROR_TYPE_ERROR,
G_VARIANT_PARSE_ERROR_UNEXPECTED_TOKEN,
G_VARIANT_PARSE_ERROR_UNKNOWN_KEYWORD,
G_VARIANT_PARSE_ERROR_UNTERMINATED_STRING_CONSTANT,
G_VARIANT_PARSE_ERROR_VALUE_EXPECTED
} GVariantParseError;
#define G_VARIANT_PARSE_ERROR (g_variant_parser_get_error_quark ()) #define G_VARIANT_PARSE_ERROR (g_variant_parser_get_error_quark ())
GQuark g_variant_parser_get_error_quark (vo id); GQuark g_variant_parser_get_error_quark (vo id);
GVariantBuilder * g_variant_builder_new (co nst GVariantType *type); GVariantBuilder * g_variant_builder_new (co nst GVariantType *type);
void g_variant_builder_unref (GV ariantBuilder *builder); void g_variant_builder_unref (GV ariantBuilder *builder);
GVariantBuilder * g_variant_builder_ref (GV ariantBuilder *builder); GVariantBuilder * g_variant_builder_ref (GV ariantBuilder *builder);
void g_variant_builder_init (GV ariantBuilder *builder, void g_variant_builder_init (GV ariantBuilder *builder,
co nst GVariantType *type); co nst GVariantType *type);
GVariant * g_variant_builder_end (GV ariantBuilder *builder); GVariant * g_variant_builder_end (GV ariantBuilder *builder);
void g_variant_builder_clear (GV ariantBuilder *builder); void g_variant_builder_clear (GV ariantBuilder *builder);
void g_variant_builder_open (GV ariantBuilder *builder, void g_variant_builder_open (GV ariantBuilder *builder,
co nst GVariantType *type); co nst GVariantType *type);
void g_variant_builder_close (GV ariantBuilder *builder); void g_variant_builder_close (GV ariantBuilder *builder);
void g_variant_builder_add_value (GV ariantBuilder *builder, void g_variant_builder_add_value (GV ariantBuilder *builder,
GV ariant *value); GV ariant *value);
void g_variant_builder_add (GV ariantBuilder *builder, void g_variant_builder_add (GV ariantBuilder *builder,
co nst gchar *format_string, co nst gchar *format_string,
.. .); .. .);
void g_variant_builder_add_parsed (GV
ariantBuilder *builder,
co
nst gchar *format,
..
.);
GVariant * g_variant_new (co nst gchar *format_string, GVariant * g_variant_new (co nst gchar *format_string,
.. .); .. .);
void g_variant_get (GV ariant *value, void g_variant_get (GV ariant *value,
co nst gchar *format_string, co nst gchar *format_string,
.. .); .. .);
GVariant * g_variant_new_va (co nst gchar *format_string, GVariant * g_variant_new_va (co nst gchar *format_string,
co nst gchar **endptr, co nst gchar **endptr,
va _list *app); va _list *app);
void g_variant_get_va (GV ariant *value, void g_variant_get_va (GV ariant *value,
skipping to change at line 220 skipping to change at line 266
GVariant * g_variant_parse (co nst GVariantType *type, GVariant * g_variant_parse (co nst GVariantType *type,
co nst gchar *text, co nst gchar *text,
co nst gchar *limit, co nst gchar *limit,
co nst gchar **endptr, co nst gchar **endptr,
GE rror **error); GE rror **error);
GVariant * g_variant_new_parsed (co nst gchar *format, GVariant * g_variant_new_parsed (co nst gchar *format,
.. .); .. .);
GVariant * g_variant_new_parsed_va (co nst gchar *format, GVariant * g_variant_new_parsed_va (co nst gchar *format,
va _list *app); va _list *app);
gint g_variant_compare (gc
onstpointer one,
gc
onstpointer two);
G_END_DECLS G_END_DECLS
#endif /* __G_VARIANT_H__ */ #endif /* __G_VARIANT_H__ */
 End of changes. 10 change blocks. 
21 lines changed or deleted 92 lines changed or added

This html diff was produced by rfcdiff 1.41. The latest version is available from http://tools.ietf.org/tools/rfcdiff/