/* rygel-external-container.c generated by valac 0.30.0.35-2c9e8, the Vala compiler
 * generated from rygel-external-container.vala, do not modify */

/*
 * Copyright (C) 2009 Zeeshan Ali (Khattak) <zeeshanak@gnome.org>.
 * Copyright (C) 2009,2010 Nokia Corporation.
 *
 * Author: Zeeshan Ali (Khattak) <zeeshanak@gnome.org>
 *                               <zeeshan.ali@nokia.com>
 *
 * This file is part of Rygel.
 *
 * Rygel is free software; you can redistribute it and/or modify
 * it under the terms of the GNU Lesser General Public
 * License as published by the Free Software Foundation; either
 * version 2.1 of the License, or (at your option) any later version.
 *
 * Rygel is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
 * Lesser General Public License for more details.
 *
 * You should have received a copy of the GNU Lesser General Public
 * License along with this library; if not, write to the Free Software
 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301  USA
 */

#include <glib.h>
#include <glib-object.h>
#include <rygel-server.h>
#include <gio/gio.h>
#include <stdlib.h>
#include <string.h>
#include <gee.h>
#include <libgupnp-av/gupnp-av.h>


#define RYGEL_EXTERNAL_TYPE_CONTAINER (rygel_external_container_get_type ())
#define RYGEL_EXTERNAL_CONTAINER(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), RYGEL_EXTERNAL_TYPE_CONTAINER, RygelExternalContainer))
#define RYGEL_EXTERNAL_CONTAINER_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), RYGEL_EXTERNAL_TYPE_CONTAINER, RygelExternalContainerClass))
#define RYGEL_EXTERNAL_IS_CONTAINER(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), RYGEL_EXTERNAL_TYPE_CONTAINER))
#define RYGEL_EXTERNAL_IS_CONTAINER_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), RYGEL_EXTERNAL_TYPE_CONTAINER))
#define RYGEL_EXTERNAL_CONTAINER_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), RYGEL_EXTERNAL_TYPE_CONTAINER, RygelExternalContainerClass))

typedef struct _RygelExternalContainer RygelExternalContainer;
typedef struct _RygelExternalContainerClass RygelExternalContainerClass;
typedef struct _RygelExternalContainerPrivate RygelExternalContainerPrivate;

#define RYGEL_EXTERNAL_TYPE_MEDIA_OBJECT_PROXY (rygel_external_media_object_proxy_get_type ())
#define RYGEL_EXTERNAL_MEDIA_OBJECT_PROXY(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), RYGEL_EXTERNAL_TYPE_MEDIA_OBJECT_PROXY, RygelExternalMediaObjectProxy))
#define RYGEL_EXTERNAL_IS_MEDIA_OBJECT_PROXY(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), RYGEL_EXTERNAL_TYPE_MEDIA_OBJECT_PROXY))
#define RYGEL_EXTERNAL_MEDIA_OBJECT_PROXY_GET_INTERFACE(obj) (G_TYPE_INSTANCE_GET_INTERFACE ((obj), RYGEL_EXTERNAL_TYPE_MEDIA_OBJECT_PROXY, RygelExternalMediaObjectProxyIface))

typedef struct _RygelExternalMediaObjectProxy RygelExternalMediaObjectProxy;
typedef struct _RygelExternalMediaObjectProxyIface RygelExternalMediaObjectProxyIface;

#define RYGEL_EXTERNAL_TYPE_MEDIA_OBJECT_PROXY_PROXY (rygel_external_media_object_proxy_proxy_get_type ())

#define RYGEL_EXTERNAL_TYPE_MEDIA_CONTAINER_PROXY (rygel_external_media_container_proxy_get_type ())
#define RYGEL_EXTERNAL_MEDIA_CONTAINER_PROXY(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), RYGEL_EXTERNAL_TYPE_MEDIA_CONTAINER_PROXY, RygelExternalMediaContainerProxy))
#define RYGEL_EXTERNAL_IS_MEDIA_CONTAINER_PROXY(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), RYGEL_EXTERNAL_TYPE_MEDIA_CONTAINER_PROXY))
#define RYGEL_EXTERNAL_MEDIA_CONTAINER_PROXY_GET_INTERFACE(obj) (G_TYPE_INSTANCE_GET_INTERFACE ((obj), RYGEL_EXTERNAL_TYPE_MEDIA_CONTAINER_PROXY, RygelExternalMediaContainerProxyIface))

typedef struct _RygelExternalMediaContainerProxy RygelExternalMediaContainerProxy;
typedef struct _RygelExternalMediaContainerProxyIface RygelExternalMediaContainerProxyIface;

#define RYGEL_EXTERNAL_TYPE_MEDIA_CONTAINER_PROXY_PROXY (rygel_external_media_container_proxy_proxy_get_type ())

#define RYGEL_EXTERNAL_TYPE_ITEM_FACTORY (rygel_external_item_factory_get_type ())
#define RYGEL_EXTERNAL_ITEM_FACTORY(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), RYGEL_EXTERNAL_TYPE_ITEM_FACTORY, RygelExternalItemFactory))
#define RYGEL_EXTERNAL_ITEM_FACTORY_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), RYGEL_EXTERNAL_TYPE_ITEM_FACTORY, RygelExternalItemFactoryClass))
#define RYGEL_EXTERNAL_IS_ITEM_FACTORY(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), RYGEL_EXTERNAL_TYPE_ITEM_FACTORY))
#define RYGEL_EXTERNAL_IS_ITEM_FACTORY_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), RYGEL_EXTERNAL_TYPE_ITEM_FACTORY))
#define RYGEL_EXTERNAL_ITEM_FACTORY_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), RYGEL_EXTERNAL_TYPE_ITEM_FACTORY, RygelExternalItemFactoryClass))

typedef struct _RygelExternalItemFactory RygelExternalItemFactory;
typedef struct _RygelExternalItemFactoryClass RygelExternalItemFactoryClass;
#define _g_object_unref0(var) ((var == NULL) ? NULL : (var = (g_object_unref (var), NULL)))
#define _g_free0(var) (var = (g_free (var), NULL))
#define _rygel_external_item_factory_unref0(var) ((var == NULL) ? NULL : (var = (rygel_external_item_factory_unref (var), NULL)))
typedef struct _RygelExternalContainerGetChildrenData RygelExternalContainerGetChildrenData;
#define _rygel_search_expression_unref0(var) ((var == NULL) ? NULL : (var = (rygel_search_expression_unref (var), NULL)))
typedef struct _RygelExternalContainerSearchData RygelExternalContainerSearchData;

#define RYGEL_EXTERNAL_FREE_DESKTOP_TYPE_PROPERTIES (rygel_external_free_desktop_properties_get_type ())
#define RYGEL_EXTERNAL_FREE_DESKTOP_PROPERTIES(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), RYGEL_EXTERNAL_FREE_DESKTOP_TYPE_PROPERTIES, RygelExternalFreeDesktopProperties))
#define RYGEL_EXTERNAL_FREE_DESKTOP_IS_PROPERTIES(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), RYGEL_EXTERNAL_FREE_DESKTOP_TYPE_PROPERTIES))
#define RYGEL_EXTERNAL_FREE_DESKTOP_PROPERTIES_GET_INTERFACE(obj) (G_TYPE_INSTANCE_GET_INTERFACE ((obj), RYGEL_EXTERNAL_FREE_DESKTOP_TYPE_PROPERTIES, RygelExternalFreeDesktopPropertiesIface))

typedef struct _RygelExternalFreeDesktopProperties RygelExternalFreeDesktopProperties;
typedef struct _RygelExternalFreeDesktopPropertiesIface RygelExternalFreeDesktopPropertiesIface;

#define RYGEL_EXTERNAL_FREE_DESKTOP_TYPE_PROPERTIES_PROXY (rygel_external_free_desktop_properties_proxy_get_type ())
#define _g_hash_table_unref0(var) ((var == NULL) ? NULL : (var = (g_hash_table_unref (var), NULL)))

#define RYGEL_EXTERNAL_TYPE_DUMMY_CONTAINER (rygel_external_dummy_container_get_type ())
#define RYGEL_EXTERNAL_DUMMY_CONTAINER(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), RYGEL_EXTERNAL_TYPE_DUMMY_CONTAINER, RygelExternalDummyContainer))
#define RYGEL_EXTERNAL_DUMMY_CONTAINER_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), RYGEL_EXTERNAL_TYPE_DUMMY_CONTAINER, RygelExternalDummyContainerClass))
#define RYGEL_EXTERNAL_IS_DUMMY_CONTAINER(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), RYGEL_EXTERNAL_TYPE_DUMMY_CONTAINER))
#define RYGEL_EXTERNAL_IS_DUMMY_CONTAINER_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), RYGEL_EXTERNAL_TYPE_DUMMY_CONTAINER))
#define RYGEL_EXTERNAL_DUMMY_CONTAINER_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), RYGEL_EXTERNAL_TYPE_DUMMY_CONTAINER, RygelExternalDummyContainerClass))

typedef struct _RygelExternalDummyContainer RygelExternalDummyContainer;
typedef struct _RygelExternalDummyContainerClass RygelExternalDummyContainerClass;
typedef struct _RygelExternalContainerFindObjectData RygelExternalContainerFindObjectData;
typedef struct _RygelExternalContainerCreateMediaObjectsData RygelExternalContainerCreateMediaObjectsData;
typedef struct _RygelExternalContainerRefreshChildContainersData RygelExternalContainerRefreshChildContainersData;
#define _g_error_free0(var) ((var == NULL) ? NULL : (var = (g_error_free (var), NULL)))
typedef struct _RygelExternalContainerUpdateContainerData RygelExternalContainerUpdateContainerData;

struct _RygelExternalMediaObjectProxyIface {
	GTypeInterface parent_iface;
	char* (*get_parent) (RygelExternalMediaObjectProxy* self);
	void (*set_parent) (RygelExternalMediaObjectProxy* self, const char* value);
	gchar* (*get_display_name) (RygelExternalMediaObjectProxy* self);
	void (*set_display_name) (RygelExternalMediaObjectProxy* self, const gchar* value);
	gchar* (*get_object_type) (RygelExternalMediaObjectProxy* self);
	void (*set_object_type) (RygelExternalMediaObjectProxy* self, const gchar* value);
};

struct _RygelExternalMediaContainerProxyIface {
	GTypeInterface parent_iface;
	void (*list_children) (RygelExternalMediaContainerProxy* self, guint offset, guint max_count, gchar** filter, int filter_length1, GAsyncReadyCallback _callback_, gpointer _user_data_);
	GHashTable** (*list_children_finish) (RygelExternalMediaContainerProxy* self, GAsyncResult* _res_, int* result_length1, GError** error);
	void (*list_containers) (RygelExternalMediaContainerProxy* self, guint offset, guint max_count, gchar** filter, int filter_length1, GAsyncReadyCallback _callback_, gpointer _user_data_);
	GHashTable** (*list_containers_finish) (RygelExternalMediaContainerProxy* self, GAsyncResult* _res_, int* result_length1, GError** error);
	void (*list_items) (RygelExternalMediaContainerProxy* self, guint offset, guint max_count, gchar** filter, int filter_length1, GAsyncReadyCallback _callback_, gpointer _user_data_);
	GHashTable** (*list_items_finish) (RygelExternalMediaContainerProxy* self, GAsyncResult* _res_, int* result_length1, GError** error);
	void (*search_objects) (RygelExternalMediaContainerProxy* self, const gchar* query, guint offset, guint max_count, gchar** filter, int filter_length1, GAsyncReadyCallback _callback_, gpointer _user_data_);
	GHashTable** (*search_objects_finish) (RygelExternalMediaContainerProxy* self, GAsyncResult* _res_, int* result_length1, GError** error);
	guint (*get_child_count) (RygelExternalMediaContainerProxy* self);
	void (*set_child_count) (RygelExternalMediaContainerProxy* self, guint value);
	guint (*get_item_count) (RygelExternalMediaContainerProxy* self);
	void (*set_item_count) (RygelExternalMediaContainerProxy* self, guint value);
	guint (*get_container_count) (RygelExternalMediaContainerProxy* self);
	void (*set_container_count) (RygelExternalMediaContainerProxy* self, guint value);
	gboolean (*get_searchable) (RygelExternalMediaContainerProxy* self);
	void (*set_searchable) (RygelExternalMediaContainerProxy* self, gboolean value);
	char* (*get_icon) (RygelExternalMediaContainerProxy* self);
	void (*set_icon) (RygelExternalMediaContainerProxy* self, const char* value);
};

struct _RygelExternalContainer {
	RygelMediaContainer parent_instance;
	RygelExternalContainerPrivate * priv;
	RygelExternalMediaContainerProxy* actual_container;
	gchar* service_name;
};

struct _RygelExternalContainerClass {
	RygelMediaContainerClass parent_class;
};

struct _RygelExternalContainerPrivate {
	RygelExternalItemFactory* item_factory;
	GeeArrayList* containers;
	GeeArrayList* _search_classes;
	gboolean searchable;
};

struct _RygelExternalContainerGetChildrenData {
	int _state_;
	GObject* _source_object_;
	GAsyncResult* _res_;
	GSimpleAsyncResult* _async_result;
	RygelExternalContainer* self;
	guint offset;
	guint max_count;
	gchar* sort_criteria;
	GCancellable* cancellable;
	RygelMediaObjects* result;
	gchar** filter;
	gchar** _tmp0_;
	gint filter_length1;
	gint _filter_size_;
	const gchar** object_prop_collection;
	gint object_prop_collection_length1;
	gint _object_prop_collection_size_;
	gint object_prop_it;
	const gchar* object_prop;
	gchar** _tmp1_;
	gint _tmp1__length1;
	const gchar* _tmp2_;
	gchar* _tmp3_;
	const gchar** container_prop_collection;
	gint container_prop_collection_length1;
	gint _container_prop_collection_size_;
	gint container_prop_it;
	const gchar* container_prop;
	gchar** _tmp4_;
	gint _tmp4__length1;
	const gchar* _tmp5_;
	gchar* _tmp6_;
	const gchar** item_prop_collection;
	gint item_prop_collection_length1;
	gint _item_prop_collection_size_;
	gint item_prop_it;
	const gchar* item_prop;
	gchar** _tmp7_;
	gint _tmp7__length1;
	const gchar* _tmp8_;
	gchar* _tmp9_;
	GHashTable** children_props;
	RygelExternalMediaContainerProxy* _tmp10_;
	guint _tmp11_;
	guint _tmp12_;
	gchar** _tmp13_;
	gint _tmp13__length1;
	gint _tmp14_;
	GHashTable** _tmp15_;
	gint children_props_length1;
	gint _children_props_size_;
	RygelMediaObjects* _result_;
	GHashTable** _tmp16_;
	gint _tmp16__length1;
	RygelMediaObjects* _tmp17_;
	RygelMediaObjects* _tmp18_;
	const gchar* _tmp19_;
	GError * _inner_error_;
};

struct _RygelExternalContainerSearchData {
	int _state_;
	GObject* _source_object_;
	GAsyncResult* _res_;
	GSimpleAsyncResult* _async_result;
	RygelExternalContainer* self;
	RygelSearchExpression* expression;
	guint offset;
	guint max_count;
	guint total_matches;
	gchar* sort_criteria;
	GCancellable* cancellable;
	RygelMediaObjects* result;
	gboolean _tmp0_;
	RygelSearchExpression* _tmp1_;
	gboolean _tmp2_;
	RygelMediaObjects* _tmp3_;
	RygelSearchExpression* _tmp4_;
	guint _tmp5_;
	guint _tmp6_;
	const gchar* _tmp7_;
	GCancellable* _tmp8_;
	guint _tmp9_;
	RygelMediaObjects* _tmp10_;
	RygelMediaObjects* _tmp11_;
	gchar** filter;
	gchar** _tmp12_;
	gint filter_length1;
	gint _filter_size_;
	const gchar** object_prop_collection;
	gint object_prop_collection_length1;
	gint _object_prop_collection_size_;
	gint object_prop_it;
	const gchar* object_prop;
	gchar** _tmp13_;
	gint _tmp13__length1;
	const gchar* _tmp14_;
	gchar* _tmp15_;
	const gchar** container_prop_collection;
	gint container_prop_collection_length1;
	gint _container_prop_collection_size_;
	gint container_prop_it;
	const gchar* container_prop;
	gchar** _tmp16_;
	gint _tmp16__length1;
	const gchar* _tmp17_;
	gchar* _tmp18_;
	const gchar** item_prop_collection;
	gint item_prop_collection_length1;
	gint _item_prop_collection_size_;
	gint item_prop_it;
	const gchar* item_prop;
	gchar** _tmp19_;
	gint _tmp19__length1;
	const gchar* _tmp20_;
	gchar* _tmp21_;
	RygelSearchExpression* ext_expression;
	RygelSearchExpression* _tmp22_;
	RygelSearchExpression* _tmp23_;
	GHashTable** _result_;
	RygelExternalMediaContainerProxy* _tmp24_;
	RygelSearchExpression* _tmp25_;
	gchar* _tmp26_;
	gchar* _tmp27_;
	guint _tmp28_;
	guint _tmp29_;
	gchar** _tmp30_;
	gint _tmp30__length1;
	gint _tmp31_;
	GHashTable** _tmp32_;
	GHashTable** _tmp33_;
	gint _tmp33__length1;
	gint _result__length1;
	gint __result__size_;
	GHashTable** _tmp34_;
	gint _tmp34__length1;
	RygelMediaObjects* objects;
	GHashTable** _tmp35_;
	gint _tmp35__length1;
	RygelMediaObjects* _tmp36_;
	RygelMediaObjects* _tmp37_;
	const gchar* _tmp38_;
	GError * _inner_error_;
};

struct _RygelExternalFreeDesktopPropertiesIface {
	GTypeInterface parent_iface;
	void (*get_all) (RygelExternalFreeDesktopProperties* self, const gchar* iface, GAsyncReadyCallback _callback_, gpointer _user_data_);
	GHashTable* (*get_all_finish) (RygelExternalFreeDesktopProperties* self, GAsyncResult* _res_, GError** error);
};

struct _RygelExternalContainerFindObjectData {
	int _state_;
	GObject* _source_object_;
	GAsyncResult* _res_;
	GSimpleAsyncResult* _async_result;
	RygelExternalContainer* self;
	gchar* id;
	GCancellable* cancellable;
	RygelMediaObject* result;
	RygelMediaObject* media_object;
	RygelExternalMediaObjectProxy* actual_object;
	const gchar* _tmp0_;
	const gchar* _tmp1_;
	RygelExternalMediaObjectProxy* _tmp2_;
	RygelExternalMediaObjectProxy* _tmp3_;
	gchar* _tmp4_;
	gchar* _tmp5_;
	gchar* _tmp6_;
	gboolean _tmp7_;
	const gchar* _tmp8_;
	RygelMediaContainer* _tmp9_;
	RygelMediaObject* _tmp10_;
	GeeArrayList* _container_list;
	GeeArrayList* _tmp11_;
	GeeArrayList* _tmp12_;
	gint _container_size;
	GeeArrayList* _tmp13_;
	gint _tmp14_;
	gint _tmp15_;
	gint _container_index;
	gint _tmp16_;
	gint _tmp17_;
	gint _tmp18_;
	RygelExternalContainer* container;
	GeeArrayList* _tmp19_;
	gint _tmp20_;
	gpointer _tmp21_;
	RygelMediaObject* _tmp22_;
	RygelExternalContainer* _tmp23_;
	const gchar* _tmp24_;
	GCancellable* _tmp25_;
	RygelMediaObject* _tmp26_;
	RygelMediaObject* _tmp27_;
	RygelMediaObject* _tmp28_;
	RygelExternalFreeDesktopProperties* props_iface;
	const gchar* _tmp29_;
	const gchar* _tmp30_;
	RygelExternalFreeDesktopProperties* _tmp31_;
	GHashTable* props;
	RygelExternalFreeDesktopProperties* _tmp32_;
	GHashTable* _tmp33_;
	guint child_count;
	GHashTable* _tmp34_;
	gconstpointer _tmp35_;
	guint _tmp36_;
	gboolean searchable;
	GHashTable* _tmp37_;
	gconstpointer _tmp38_;
	gboolean _tmp39_;
	GHashTable* _tmp40_;
	RygelExternalFreeDesktopProperties* _tmp41_;
	GHashTable* _tmp42_;
	GHashTable* _tmp43_;
	gchar* path;
	GHashTable* _tmp44_;
	gconstpointer _tmp45_;
	gchar* _tmp46_;
	gchar* title;
	GHashTable* _tmp47_;
	const gchar* _tmp48_;
	const gchar* _tmp49_;
	gchar* _tmp50_;
	RygelExternalContainer* _tmp51_;
	const gchar* _tmp52_;
	const gchar* _tmp53_;
	guint _tmp54_;
	gboolean _tmp55_;
	const gchar* _tmp56_;
	const gchar* _tmp57_;
	RygelExternalContainer* _tmp58_;
	RygelExternalContainer* _tmp59_;
	RygelExternalDummyContainer* parent_container;
	RygelExternalMediaObjectProxy* _tmp60_;
	char* _tmp61_;
	char* _tmp62_;
	gchar* _tmp63_;
	RygelExternalDummyContainer* _tmp64_;
	RygelExternalDummyContainer* _tmp65_;
	RygelExternalFreeDesktopProperties* _vala1_props_iface;
	const gchar* _tmp66_;
	const gchar* _tmp67_;
	RygelExternalFreeDesktopProperties* _tmp68_;
	GHashTable* _vala1_props;
	RygelExternalFreeDesktopProperties* _tmp69_;
	GHashTable* _tmp70_;
	RygelMediaFileItem* _tmp71_;
	RygelExternalItemFactory* _tmp72_;
	const gchar* _tmp73_;
	RygelExternalMediaObjectProxy* _tmp74_;
	gchar* _tmp75_;
	gchar* _tmp76_;
	gchar* _tmp77_;
	RygelExternalMediaObjectProxy* _tmp78_;
	gchar* _tmp79_;
	gchar* _tmp80_;
	gchar* _tmp81_;
	GHashTable* _tmp82_;
	const gchar* _tmp83_;
	RygelExternalDummyContainer* _tmp84_;
	RygelMediaFileItem* _tmp85_;
	RygelMediaFileItem* _tmp86_;
	RygelMediaFileItem* _tmp87_;
	GError * _inner_error_;
};

struct _RygelExternalContainerCreateMediaObjectsData {
	int _state_;
	GObject* _source_object_;
	GAsyncResult* _res_;
	GSimpleAsyncResult* _async_result;
	RygelExternalContainer* self;
	GHashTable** all_props;
	gint all_props_length1;
	RygelMediaContainer* parent;
	RygelMediaObjects* result;
	RygelMediaObjects* media_objects;
	RygelMediaObjects* _tmp0_;
	GHashTable** _tmp1_;
	gint _tmp1__length1;
	GHashTable** props_collection;
	gint props_collection_length1;
	gint _props_collection_size_;
	gint props_it;
	GHashTable* _tmp2_;
	GHashTable* props;
	gchar* id;
	GHashTable* _tmp3_;
	gconstpointer _tmp4_;
	gchar* _tmp5_;
	gchar* type;
	GHashTable* _tmp6_;
	gconstpointer _tmp7_;
	gchar* _tmp8_;
	RygelMediaContainer* parent_container;
	RygelMediaContainer* _tmp9_;
	RygelMediaContainer* _tmp10_;
	RygelMediaContainer* _tmp11_;
	gchar* parent_id;
	GHashTable* _tmp12_;
	gconstpointer _tmp13_;
	gchar* _tmp14_;
	const gchar* _tmp15_;
	RygelExternalDummyContainer* _tmp16_;
	RygelMediaObject* media_object;
	const gchar* _tmp17_;
	const gchar* _tmp18_;
	RygelMediaContainer* _tmp19_;
	RygelMediaObject* _tmp20_;
	gchar* title;
	GHashTable* _tmp21_;
	const gchar* _tmp22_;
	const gchar* _tmp23_;
	gchar* _tmp24_;
	const gchar* _tmp25_;
	guint child_count;
	GHashTable* _tmp26_;
	gconstpointer _tmp27_;
	guint _tmp28_;
	const gchar* _tmp29_;
	const gchar* _tmp30_;
	guint _tmp31_;
	RygelMediaContainer* _tmp32_;
	RygelExternalDummyContainer* _tmp33_;
	RygelMediaFileItem* _tmp34_;
	RygelExternalItemFactory* _tmp35_;
	const gchar* _tmp36_;
	const gchar* _tmp37_;
	const gchar* _tmp38_;
	GHashTable* _tmp39_;
	const gchar* _tmp40_;
	RygelMediaContainer* _tmp41_;
	RygelMediaFileItem* _tmp42_;
	RygelMediaFileItem* _tmp43_;
	RygelMediaObjects* _tmp44_;
	RygelMediaObject* _tmp45_;
	GError * _inner_error_;
};

struct _RygelExternalContainerRefreshChildContainersData {
	int _state_;
	GObject* _source_object_;
	GAsyncResult* _res_;
	GSimpleAsyncResult* _async_result;
	RygelExternalContainer* self;
	gchar** filter;
	gchar** _tmp0_;
	gint filter_length1;
	gint _filter_size_;
	const gchar** object_prop_collection;
	gint object_prop_collection_length1;
	gint _object_prop_collection_size_;
	gint object_prop_it;
	const gchar* object_prop;
	gchar** _tmp1_;
	gint _tmp1__length1;
	const gchar* _tmp2_;
	gchar* _tmp3_;
	const gchar** container_prop_collection;
	gint container_prop_collection_length1;
	gint _container_prop_collection_size_;
	gint container_prop_it;
	const gchar* container_prop;
	gchar** _tmp4_;
	gint _tmp4__length1;
	const gchar* _tmp5_;
	gchar* _tmp6_;
	GHashTable** children_props;
	RygelExternalMediaContainerProxy* _tmp7_;
	gchar** _tmp8_;
	gint _tmp8__length1;
	gint _tmp9_;
	GHashTable** _tmp10_;
	gint children_props_length1;
	gint _children_props_size_;
	GeeArrayList* _tmp11_;
	GHashTable** _tmp12_;
	gint _tmp12__length1;
	GHashTable** props_collection;
	gint props_collection_length1;
	gint _props_collection_size_;
	gint props_it;
	GHashTable* _tmp13_;
	GHashTable* props;
	gchar* path;
	GHashTable* _tmp14_;
	gconstpointer _tmp15_;
	gchar* _tmp16_;
	gchar* title;
	GHashTable* _tmp17_;
	gconstpointer _tmp18_;
	gchar* _tmp19_;
	guint child_count;
	GHashTable* _tmp20_;
	gconstpointer _tmp21_;
	guint _tmp22_;
	gboolean searchable;
	GHashTable* _tmp23_;
	gconstpointer _tmp24_;
	gboolean _tmp25_;
	RygelExternalContainer* container;
	const gchar* _tmp26_;
	const gchar* _tmp27_;
	guint _tmp28_;
	gboolean _tmp29_;
	const gchar* _tmp30_;
	const gchar* _tmp31_;
	RygelExternalContainer* _tmp32_;
	GeeArrayList* _tmp33_;
	RygelExternalContainer* _tmp34_;
	GError * _inner_error_;
};

struct _RygelExternalContainerUpdateContainerData {
	int _state_;
	GObject* _source_object_;
	GAsyncResult* _res_;
	GSimpleAsyncResult* _async_result;
	RygelExternalContainer* self;
	gboolean connect_signal;
	RygelExternalFreeDesktopProperties* props_iface;
	const gchar* _tmp0_;
	RygelExternalMediaContainerProxy* _tmp1_;
	const gchar* _tmp2_;
	RygelExternalFreeDesktopProperties* _tmp3_;
	GHashTable* props;
	RygelExternalFreeDesktopProperties* _tmp4_;
	GHashTable* _tmp5_;
	guint child_count;
	GHashTable* _tmp6_;
	gconstpointer _tmp7_;
	guint _tmp8_;
	guint _tmp9_;
	guint _tmp10_;
	GHashTable* _tmp11_;
	RygelExternalFreeDesktopProperties* _tmp12_;
	GHashTable* _tmp13_;
	GHashTable* _tmp14_;
	GHashTable* _tmp15_;
	const gchar* _tmp16_;
	const gchar* _tmp17_;
	const gchar* _tmp18_;
	gchar* _tmp19_;
	gchar* _tmp20_;
	GError* property_error;
	RygelExternalMediaContainerProxy* _tmp21_;
	const gchar* _tmp22_;
	GError* _tmp23_;
	const gchar* _tmp24_;
	gint _tmp25_;
	gint _tmp26_;
	GError* err;
	RygelExternalMediaContainerProxy* _tmp27_;
	const gchar* _tmp28_;
	GError* _tmp29_;
	const gchar* _tmp30_;
	gboolean _tmp31_;
	RygelExternalMediaContainerProxy* _tmp32_;
	GError * _inner_error_;
};


static gpointer rygel_external_container_parent_class = NULL;
static RygelSearchableContainerIface* rygel_external_container_rygel_searchable_container_parent_iface = NULL;

GType rygel_external_container_get_type (void) G_GNUC_CONST;
GType rygel_external_media_object_proxy_get_type (void) G_GNUC_CONST;
GType rygel_external_media_object_proxy_proxy_get_type (void) G_GNUC_CONST;
guint rygel_external_media_object_proxy_register_object (void* object, GDBusConnection* connection, const gchar* path, GError** error);
GType rygel_external_media_container_proxy_proxy_get_type (void) G_GNUC_CONST;
guint rygel_external_media_container_proxy_register_object (void* object, GDBusConnection* connection, const gchar* path, GError** error);
GType rygel_external_media_container_proxy_get_type (void) G_GNUC_CONST;
gpointer rygel_external_item_factory_ref (gpointer instance);
void rygel_external_item_factory_unref (gpointer instance);
GParamSpec* rygel_external_param_spec_item_factory (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags);
void rygel_external_value_set_item_factory (GValue* value, gpointer v_object);
void rygel_external_value_take_item_factory (GValue* value, gpointer v_object);
gpointer rygel_external_value_get_item_factory (const GValue* value);
GType rygel_external_item_factory_get_type (void) G_GNUC_CONST;
#define RYGEL_EXTERNAL_CONTAINER_GET_PRIVATE(o) (G_TYPE_INSTANCE_GET_PRIVATE ((o), RYGEL_EXTERNAL_TYPE_CONTAINER, RygelExternalContainerPrivate))
enum  {
	RYGEL_EXTERNAL_CONTAINER_DUMMY_PROPERTY,
	RYGEL_EXTERNAL_CONTAINER_SEARCH_CLASSES
};
RygelExternalContainer* rygel_external_container_new (const gchar* id, const gchar* title, guint child_count, gboolean searchable, const gchar* service_name, const gchar* path, RygelExternalContainer* parent, GError** error);
RygelExternalContainer* rygel_external_container_construct (GType object_type, const gchar* id, const gchar* title, guint child_count, gboolean searchable, const gchar* service_name, const gchar* path, RygelExternalContainer* parent, GError** error);
RygelExternalItemFactory* rygel_external_item_factory_new (void);
RygelExternalItemFactory* rygel_external_item_factory_construct (GType object_type);
static void rygel_external_container_update_container (RygelExternalContainer* self, gboolean connect_signal, GAsyncReadyCallback _callback_, gpointer _user_data_);
static void rygel_external_container_update_container_finish (RygelExternalContainer* self, GAsyncResult* _res_);
static void rygel_external_container_real_get_children_data_free (gpointer _data);
static void rygel_external_container_real_get_children (RygelMediaContainer* base, guint offset, guint max_count, const gchar* sort_criteria, GCancellable* cancellable, GAsyncReadyCallback _callback_, gpointer _user_data_);
static gboolean rygel_external_container_real_get_children_co (RygelExternalContainerGetChildrenData* _data_);
static void _vala_array_add1 (gchar*** array, int* length, int* size, gchar* value);
static void _vala_array_add2 (gchar*** array, int* length, int* size, gchar* value);
static void _vala_array_add3 (gchar*** array, int* length, int* size, gchar* value);
void rygel_external_media_container_proxy_list_children (RygelExternalMediaContainerProxy* self, guint offset, guint max_count, gchar** filter, int filter_length1, GAsyncReadyCallback _callback_, gpointer _user_data_);
GHashTable** rygel_external_media_container_proxy_list_children_finish (RygelExternalMediaContainerProxy* self, GAsyncResult* _res_, int* result_length1, GError** error);
static void rygel_external_container_get_children_ready (GObject* source_object, GAsyncResult* _res_, gpointer _user_data_);
static void rygel_external_container_create_media_objects (RygelExternalContainer* self, GHashTable** all_props, int all_props_length1, RygelMediaContainer* parent, GAsyncReadyCallback _callback_, gpointer _user_data_);
static RygelMediaObjects* rygel_external_container_create_media_objects_finish (RygelExternalContainer* self, GAsyncResult* _res_, GError** error);
static void rygel_external_container_real_search_data_free (gpointer _data);
static void rygel_external_container_real_search (RygelSearchableContainer* base, RygelSearchExpression* expression, guint offset, guint max_count, const gchar* sort_criteria, GCancellable* cancellable, GAsyncReadyCallback _callback_, gpointer _user_data_);
static gboolean rygel_external_container_real_search_co (RygelExternalContainerSearchData* _data_);
static void rygel_external_container_search_ready (GObject* source_object, GAsyncResult* _res_, gpointer _user_data_);
static void _vala_array_add4 (gchar*** array, int* length, int* size, gchar* value);
static void _vala_array_add5 (gchar*** array, int* length, int* size, gchar* value);
static void _vala_array_add6 (gchar*** array, int* length, int* size, gchar* value);
static RygelSearchExpression* rygel_external_container_translate_expression (RygelExternalContainer* self, RygelSearchExpression* upnp_expression);
void rygel_external_media_container_proxy_search_objects (RygelExternalMediaContainerProxy* self, const gchar* query, guint offset, guint max_count, gchar** filter, int filter_length1, GAsyncReadyCallback _callback_, gpointer _user_data_);
GHashTable** rygel_external_media_container_proxy_search_objects_finish (RygelExternalMediaContainerProxy* self, GAsyncResult* _res_, int* result_length1, GError** error);
static void rygel_external_container_real_find_object_data_free (gpointer _data);
static void rygel_external_container_real_find_object (RygelMediaContainer* base, const gchar* id, GCancellable* cancellable, GAsyncReadyCallback _callback_, gpointer _user_data_);
static gboolean rygel_external_container_real_find_object_co (RygelExternalContainerFindObjectData* _data_);
static void rygel_external_container_find_object_ready (GObject* source_object, GAsyncResult* _res_, gpointer _user_data_);
gchar* rygel_external_media_object_proxy_get_object_type (RygelExternalMediaObjectProxy* self);
static RygelMediaContainer* rygel_external_container_find_container_by_id (RygelExternalContainer* self, const gchar* id);
GType rygel_external_free_desktop_properties_proxy_get_type (void) G_GNUC_CONST;
guint rygel_external_free_desktop_properties_register_object (void* object, GDBusConnection* connection, const gchar* path, GError** error);
GType rygel_external_free_desktop_properties_get_type (void) G_GNUC_CONST;
void rygel_external_free_desktop_properties_get_all (RygelExternalFreeDesktopProperties* self, const gchar* iface, GAsyncReadyCallback _callback_, gpointer _user_data_);
GHashTable* rygel_external_free_desktop_properties_get_all_finish (RygelExternalFreeDesktopProperties* self, GAsyncResult* _res_, GError** error);
#define RYGEL_EXTERNAL_MEDIA_CONTAINER_PROXY_IFACE "org.gnome.UPnP.MediaContainer2"
static guint _variant_get1 (GVariant* value);
static gboolean _variant_get2 (GVariant* value);
#define RYGEL_EXTERNAL_MEDIA_OBJECT_PROXY_IFACE "org.gnome.UPnP.MediaObject2"
static gchar* _variant_get3 (GVariant* value);
gchar* rygel_external_get_mandatory_string_value (GHashTable* props, const gchar* key, const gchar* _default_, const gchar* service_name);
GType rygel_external_dummy_container_get_type (void) G_GNUC_CONST;
char* rygel_external_media_object_proxy_get_parent (RygelExternalMediaObjectProxy* self);
RygelExternalDummyContainer* rygel_external_dummy_container_new (const gchar* id, const gchar* title, guint child_count, RygelMediaContainer* parent);
RygelExternalDummyContainer* rygel_external_dummy_container_construct (GType object_type, const gchar* id, const gchar* title, guint child_count, RygelMediaContainer* parent);
#define RYGEL_EXTERNAL_MEDIA_ITEM_PROXY_IFACE "org.gnome.UPnP.MediaItem2"
void rygel_external_item_factory_create (RygelExternalItemFactory* self, const gchar* id, const gchar* type, const gchar* title, GHashTable* props, const gchar* service_name, RygelMediaContainer* parent, GAsyncReadyCallback _callback_, gpointer _user_data_);
RygelMediaFileItem* rygel_external_item_factory_create_finish (RygelExternalItemFactory* self, GAsyncResult* _res_, GError** error);
gchar* rygel_external_media_object_proxy_get_display_name (RygelExternalMediaObjectProxy* self);
static void rygel_external_container_create_media_objects_data_free (gpointer _data);
static gboolean rygel_external_container_create_media_objects_co (RygelExternalContainerCreateMediaObjectsData* _data_);
static gchar* _variant_get4 (GVariant* value);
static gchar* _variant_get5 (GVariant* value);
static gchar* _variant_get6 (GVariant* value);
static guint _variant_get7 (GVariant* value);
static void rygel_external_container_create_media_objects_ready (GObject* source_object, GAsyncResult* _res_, gpointer _user_data_);
static void rygel_external_container_refresh_child_containers_data_free (gpointer _data);
static void rygel_external_container_refresh_child_containers (RygelExternalContainer* self, GAsyncReadyCallback _callback_, gpointer _user_data_);
static void rygel_external_container_refresh_child_containers_finish (RygelExternalContainer* self, GAsyncResult* _res_, GError** error);
static gboolean rygel_external_container_refresh_child_containers_co (RygelExternalContainerRefreshChildContainersData* _data_);
static void _vala_array_add7 (gchar*** array, int* length, int* size, gchar* value);
static void _vala_array_add8 (gchar*** array, int* length, int* size, gchar* value);
void rygel_external_media_container_proxy_list_containers (RygelExternalMediaContainerProxy* self, guint offset, guint max_count, gchar** filter, int filter_length1, GAsyncReadyCallback _callback_, gpointer _user_data_);
GHashTable** rygel_external_media_container_proxy_list_containers_finish (RygelExternalMediaContainerProxy* self, GAsyncResult* _res_, int* result_length1, GError** error);
static void rygel_external_container_refresh_child_containers_ready (GObject* source_object, GAsyncResult* _res_, gpointer _user_data_);
static gchar* _variant_get8 (GVariant* value);
static gchar* _variant_get9 (GVariant* value);
static guint _variant_get10 (GVariant* value);
static gboolean _variant_get11 (GVariant* value);
static void rygel_external_container_update_container_data_free (gpointer _data);
static gboolean rygel_external_container_update_container_co (RygelExternalContainerUpdateContainerData* _data_);
static void rygel_external_container_update_container_ready (GObject* source_object, GAsyncResult* _res_, gpointer _user_data_);
static guint _variant_get12 (GVariant* value);
static void rygel_external_container_on_updated (RygelExternalContainer* self, RygelExternalMediaContainerProxy* actual_container);
static void _rygel_external_container_on_updated_rygel_external_media_container_proxy_updated (RygelExternalMediaContainerProxy* _sender, gpointer self);
gchar* rygel_external_container_translate_property (RygelExternalContainer* self, const gchar* property);
static void rygel_external_container_finalize (GObject* obj);
static void _vala_rygel_external_container_get_property (GObject * object, guint property_id, GValue * value, GParamSpec * pspec);
static void _vala_rygel_external_container_set_property (GObject * object, guint property_id, const GValue * value, GParamSpec * pspec);
static void _vala_array_destroy (gpointer array, gint array_length, GDestroyNotify destroy_func);
static void _vala_array_free (gpointer array, gint array_length, GDestroyNotify destroy_func);

extern const gchar* RYGEL_EXTERNAL_MEDIA_OBJECT_PROXY_PROPERTIES[4];
extern const gchar* RYGEL_EXTERNAL_MEDIA_CONTAINER_PROXY_PROPERTIES[2];
extern const gchar* RYGEL_EXTERNAL_MEDIA_ITEM_PROXY_PROPERTIES[19];

RygelExternalContainer* rygel_external_container_construct (GType object_type, const gchar* id, const gchar* title, guint child_count, gboolean searchable, const gchar* service_name, const gchar* path, RygelExternalContainer* parent, GError** error) {
	RygelExternalContainer * self = NULL;
	gint tmp = 0;
	guint _tmp0_ = 0U;
	guint _tmp1_ = 0U;
	gint _tmp2_ = 0;
	const gchar* _tmp3_ = NULL;
	RygelExternalContainer* _tmp4_ = NULL;
	const gchar* _tmp5_ = NULL;
	gint _tmp6_ = 0;
	const gchar* _tmp7_ = NULL;
	gchar* _tmp8_ = NULL;
	RygelExternalItemFactory* _tmp9_ = NULL;
	GeeArrayList* _tmp10_ = NULL;
	GeeArrayList* _tmp11_ = NULL;
	GeeArrayList* _tmp12_ = NULL;
	RygelExternalMediaContainerProxy* _tmp13_ = NULL;
	const gchar* _tmp14_ = NULL;
	const gchar* _tmp15_ = NULL;
	RygelExternalMediaContainerProxy* _tmp16_ = NULL;
	RygelExternalMediaContainerProxy* _tmp17_ = NULL;
	RygelExternalContainer* _tmp18_ = NULL;
	GError * _inner_error_ = NULL;
	g_return_val_if_fail (id != NULL, NULL);
	g_return_val_if_fail (title != NULL, NULL);
	g_return_val_if_fail (service_name != NULL, NULL);
	g_return_val_if_fail (path != NULL, NULL);
	_tmp0_ = child_count;
	_tmp1_ = CLAMP (_tmp0_, (guint) 0, (guint) G_MAXINT);
	tmp = (gint) _tmp1_;
	_tmp2_ = tmp;
	if (_tmp2_ == G_MAXINT) {
		tmp = -1;
	}
	_tmp3_ = id;
	_tmp4_ = parent;
	_tmp5_ = title;
	_tmp6_ = tmp;
	self = (RygelExternalContainer*) rygel_media_container_construct (object_type, _tmp3_, (RygelMediaContainer*) _tmp4_, _tmp5_, _tmp6_);
	_tmp7_ = service_name;
	_tmp8_ = g_strdup (_tmp7_);
	_g_free0 (self->service_name);
	self->service_name = _tmp8_;
	_tmp9_ = rygel_external_item_factory_new ();
	_rygel_external_item_factory_unref0 (self->priv->item_factory);
	self->priv->item_factory = _tmp9_;
	_tmp10_ = gee_array_list_new (RYGEL_EXTERNAL_TYPE_CONTAINER, (GBoxedCopyFunc) g_object_ref, g_object_unref, NULL, NULL, NULL);
	_g_object_unref0 (self->priv->containers);
	self->priv->containers = _tmp10_;
	_tmp11_ = gee_array_list_new (G_TYPE_STRING, (GBoxedCopyFunc) g_strdup, g_free, NULL, NULL, NULL);
	_tmp12_ = _tmp11_;
	rygel_searchable_container_set_search_classes ((RygelSearchableContainer*) self, _tmp12_);
	_g_object_unref0 (_tmp12_);
	rygel_media_container_set_sort_criteria ((RygelMediaContainer*) self, "");
	_tmp14_ = self->service_name;
	_tmp15_ = path;
	_tmp16_ = g_initable_new (RYGEL_EXTERNAL_TYPE_MEDIA_CONTAINER_PROXY_PROXY, NULL, &_inner_error_, "g-flags", G_DBUS_PROXY_FLAGS_DO_NOT_LOAD_PROPERTIES, "g-name", _tmp14_, "g-bus-type", G_BUS_TYPE_SESSION, "g-object-path", _tmp15_, "g-interface-name", "org.gnome.UPnP.MediaContainer2", "g-interface-info", g_type_get_qdata (RYGEL_EXTERNAL_TYPE_MEDIA_CONTAINER_PROXY, g_quark_from_static_string ("vala-dbus-interface-info")), NULL);
	_tmp13_ = (RygelExternalMediaContainerProxy*) _tmp16_;
	if (G_UNLIKELY (_inner_error_ != NULL)) {
		if (_inner_error_->domain == G_IO_ERROR) {
			g_propagate_error (error, _inner_error_);
			_g_object_unref0 (self);
			return NULL;
		} else {
			g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code);
			g_clear_error (&_inner_error_);
			return NULL;
		}
	}
	_tmp17_ = _tmp13_;
	_tmp13_ = NULL;
	_g_object_unref0 (self->actual_container);
	self->actual_container = _tmp17_;
	rygel_external_container_update_container (self, TRUE, NULL, NULL);
	_tmp18_ = parent;
	if (_tmp18_ != NULL) {
		RygelExternalContainer* _tmp19_ = NULL;
		_tmp19_ = parent;
		g_object_add_weak_pointer ((GObject*) _tmp19_, &((RygelMediaObject*) self)->parent_ptr);
	}
	_g_object_unref0 (_tmp13_);
	return self;
}


RygelExternalContainer* rygel_external_container_new (const gchar* id, const gchar* title, guint child_count, gboolean searchable, const gchar* service_name, const gchar* path, RygelExternalContainer* parent, GError** error) {
	return rygel_external_container_construct (RYGEL_EXTERNAL_TYPE_CONTAINER, id, title, child_count, searchable, service_name, path, parent, error);
}


static void rygel_external_container_real_get_children_data_free (gpointer _data) {
	RygelExternalContainerGetChildrenData* _data_;
	_data_ = _data;
	_g_free0 (_data_->sort_criteria);
	_g_object_unref0 (_data_->cancellable);
	_g_object_unref0 (_data_->result);
	_g_object_unref0 (_data_->self);
	g_slice_free (RygelExternalContainerGetChildrenData, _data_);
}


static gpointer _g_object_ref0 (gpointer self) {
	return self ? g_object_ref (self) : NULL;
}


static void rygel_external_container_real_get_children (RygelMediaContainer* base, guint offset, guint max_count, const gchar* sort_criteria, GCancellable* cancellable, GAsyncReadyCallback _callback_, gpointer _user_data_) {
	RygelExternalContainer * self;
	RygelExternalContainerGetChildrenData* _data_;
	RygelExternalContainer* _tmp0_ = NULL;
	guint _tmp1_ = 0U;
	guint _tmp2_ = 0U;
	const gchar* _tmp3_ = NULL;
	gchar* _tmp4_ = NULL;
	GCancellable* _tmp5_ = NULL;
	GCancellable* _tmp6_ = NULL;
	self = (RygelExternalContainer*) base;
	_data_ = g_slice_new0 (RygelExternalContainerGetChildrenData);
	_data_->_async_result = g_simple_async_result_new (G_OBJECT (self), _callback_, _user_data_, rygel_external_container_real_get_children);
	g_simple_async_result_set_op_res_gpointer (_data_->_async_result, _data_, rygel_external_container_real_get_children_data_free);
	_tmp0_ = _g_object_ref0 (self);
	_data_->self = _tmp0_;
	_tmp1_ = offset;
	_data_->offset = _tmp1_;
	_tmp2_ = max_count;
	_data_->max_count = _tmp2_;
	_tmp3_ = sort_criteria;
	_tmp4_ = g_strdup (_tmp3_);
	_g_free0 (_data_->sort_criteria);
	_data_->sort_criteria = _tmp4_;
	_tmp5_ = cancellable;
	_tmp6_ = _g_object_ref0 (_tmp5_);
	_g_object_unref0 (_data_->cancellable);
	_data_->cancellable = _tmp6_;
	rygel_external_container_real_get_children_co (_data_);
}


static RygelMediaObjects* rygel_external_container_real_get_children_finish (RygelMediaContainer* base, GAsyncResult* _res_, GError** error) {
	RygelMediaObjects* result;
	RygelExternalContainerGetChildrenData* _data_;
	if (g_simple_async_result_propagate_error (G_SIMPLE_ASYNC_RESULT (_res_), error)) {
		return NULL;
	}
	_data_ = g_simple_async_result_get_op_res_gpointer (G_SIMPLE_ASYNC_RESULT (_res_));
	result = _data_->result;
	_data_->result = NULL;
	return result;
}


static void _vala_array_add1 (gchar*** array, int* length, int* size, gchar* value) {
	if ((*length) == (*size)) {
		*size = (*size) ? (2 * (*size)) : 4;
		*array = g_renew (gchar*, *array, (*size) + 1);
	}
	(*array)[(*length)++] = value;
	(*array)[*length] = NULL;
}


static void _vala_array_add2 (gchar*** array, int* length, int* size, gchar* value) {
	if ((*length) == (*size)) {
		*size = (*size) ? (2 * (*size)) : 4;
		*array = g_renew (gchar*, *array, (*size) + 1);
	}
	(*array)[(*length)++] = value;
	(*array)[*length] = NULL;
}


static void _vala_array_add3 (gchar*** array, int* length, int* size, gchar* value) {
	if ((*length) == (*size)) {
		*size = (*size) ? (2 * (*size)) : 4;
		*array = g_renew (gchar*, *array, (*size) + 1);
	}
	(*array)[(*length)++] = value;
	(*array)[*length] = NULL;
}


static void rygel_external_container_get_children_ready (GObject* source_object, GAsyncResult* _res_, gpointer _user_data_) {
	RygelExternalContainerGetChildrenData* _data_;
	_data_ = _user_data_;
	_data_->_source_object_ = source_object;
	_data_->_res_ = _res_;
	rygel_external_container_real_get_children_co (_data_);
}


static gboolean rygel_external_container_real_get_children_co (RygelExternalContainerGetChildrenData* _data_) {
	switch (_data_->_state_) {
		case 0:
		goto _state_0;
		case 1:
		goto _state_1;
		case 2:
		goto _state_2;
		default:
		g_assert_not_reached ();
	}
	_state_0:
	_data_->_tmp0_ = NULL;
	_data_->_tmp0_ = g_new0 (gchar*, 0 + 1);
	_data_->filter_length1 = 0;
	_data_->_filter_size_ = 0;
	_data_->filter = _data_->_tmp0_;
	_data_->filter_length1 = 0;
	_data_->_filter_size_ = _data_->filter_length1;
	{
		_data_->object_prop_collection_length1 = 0;
		_data_->_object_prop_collection_size_ = 0;
		_data_->object_prop_collection = RYGEL_EXTERNAL_MEDIA_OBJECT_PROXY_PROPERTIES;
		_data_->object_prop_collection_length1 = G_N_ELEMENTS (RYGEL_EXTERNAL_MEDIA_OBJECT_PROXY_PROPERTIES);
		for (_data_->object_prop_it = 0; _data_->object_prop_it < G_N_ELEMENTS (RYGEL_EXTERNAL_MEDIA_OBJECT_PROXY_PROPERTIES); _data_->object_prop_it = _data_->object_prop_it + 1) {
			_data_->object_prop = _data_->object_prop_collection[_data_->object_prop_it];
			{
				_data_->_tmp1_ = NULL;
				_data_->_tmp1__length1 = 0;
				_data_->_tmp1_ = _data_->filter;
				_data_->_tmp1__length1 = _data_->filter_length1;
				_data_->_tmp2_ = NULL;
				_data_->_tmp2_ = _data_->object_prop;
				_data_->_tmp3_ = NULL;
				_data_->_tmp3_ = g_strdup (_data_->_tmp2_);
				_vala_array_add1 (&_data_->filter, &_data_->filter_length1, &_data_->_filter_size_, _data_->_tmp3_);
			}
		}
	}
	{
		_data_->container_prop_collection_length1 = 0;
		_data_->_container_prop_collection_size_ = 0;
		_data_->container_prop_collection = RYGEL_EXTERNAL_MEDIA_CONTAINER_PROXY_PROPERTIES;
		_data_->container_prop_collection_length1 = G_N_ELEMENTS (RYGEL_EXTERNAL_MEDIA_CONTAINER_PROXY_PROPERTIES);
		for (_data_->container_prop_it = 0; _data_->container_prop_it < G_N_ELEMENTS (RYGEL_EXTERNAL_MEDIA_CONTAINER_PROXY_PROPERTIES); _data_->container_prop_it = _data_->container_prop_it + 1) {
			_data_->container_prop = _data_->container_prop_collection[_data_->container_prop_it];
			{
				_data_->_tmp4_ = NULL;
				_data_->_tmp4__length1 = 0;
				_data_->_tmp4_ = _data_->filter;
				_data_->_tmp4__length1 = _data_->filter_length1;
				_data_->_tmp5_ = NULL;
				_data_->_tmp5_ = _data_->container_prop;
				_data_->_tmp6_ = NULL;
				_data_->_tmp6_ = g_strdup (_data_->_tmp5_);
				_vala_array_add2 (&_data_->filter, &_data_->filter_length1, &_data_->_filter_size_, _data_->_tmp6_);
			}
		}
	}
	{
		_data_->item_prop_collection_length1 = 0;
		_data_->_item_prop_collection_size_ = 0;
		_data_->item_prop_collection = RYGEL_EXTERNAL_MEDIA_ITEM_PROXY_PROPERTIES;
		_data_->item_prop_collection_length1 = G_N_ELEMENTS (RYGEL_EXTERNAL_MEDIA_ITEM_PROXY_PROPERTIES);
		for (_data_->item_prop_it = 0; _data_->item_prop_it < G_N_ELEMENTS (RYGEL_EXTERNAL_MEDIA_ITEM_PROXY_PROPERTIES); _data_->item_prop_it = _data_->item_prop_it + 1) {
			_data_->item_prop = _data_->item_prop_collection[_data_->item_prop_it];
			{
				_data_->_tmp7_ = NULL;
				_data_->_tmp7__length1 = 0;
				_data_->_tmp7_ = _data_->filter;
				_data_->_tmp7__length1 = _data_->filter_length1;
				_data_->_tmp8_ = NULL;
				_data_->_tmp8_ = _data_->item_prop;
				_data_->_tmp9_ = NULL;
				_data_->_tmp9_ = g_strdup (_data_->_tmp8_);
				_vala_array_add3 (&_data_->filter, &_data_->filter_length1, &_data_->_filter_size_, _data_->_tmp9_);
			}
		}
	}
	_data_->_tmp10_ = NULL;
	_data_->_tmp10_ = _data_->self->actual_container;
	_data_->_tmp11_ = 0U;
	_data_->_tmp11_ = _data_->offset;
	_data_->_tmp12_ = 0U;
	_data_->_tmp12_ = _data_->max_count;
	_data_->_tmp13_ = NULL;
	_data_->_tmp13__length1 = 0;
	_data_->_tmp13_ = _data_->filter;
	_data_->_tmp13__length1 = _data_->filter_length1;
	_data_->_tmp14_ = 0;
	_data_->_state_ = 1;
	rygel_external_media_container_proxy_list_children (_data_->_tmp10_, _data_->_tmp11_, _data_->_tmp12_, _data_->_tmp13_, _data_->_tmp13__length1, rygel_external_container_get_children_ready, _data_);
	return FALSE;
	_state_1:
	_data_->_tmp15_ = NULL;
	_data_->_tmp15_ = rygel_external_media_container_proxy_list_children_finish (_data_->_tmp10_, _data_->_res_, &_data_->_tmp14_, &_data_->_inner_error_);
	_data_->children_props_length1 = 0;
	_data_->_children_props_size_ = 0;
	_data_->children_props = _data_->_tmp15_;
	_data_->children_props_length1 = _data_->_tmp14_;
	_data_->_children_props_size_ = _data_->children_props_length1;
	if (G_UNLIKELY (_data_->_inner_error_ != NULL)) {
		g_simple_async_result_set_from_error (_data_->_async_result, _data_->_inner_error_);
		g_error_free (_data_->_inner_error_);
		_data_->filter = (_vala_array_free (_data_->filter, _data_->filter_length1, (GDestroyNotify) g_free), NULL);
		if (_data_->_state_ == 0) {
			g_simple_async_result_complete_in_idle (_data_->_async_result);
		} else {
			g_simple_async_result_complete (_data_->_async_result);
		}
		g_object_unref (_data_->_async_result);
		return FALSE;
	}
	_data_->_tmp16_ = NULL;
	_data_->_tmp16__length1 = 0;
	_data_->_tmp16_ = _data_->children_props;
	_data_->_tmp16__length1 = _data_->children_props_length1;
	_data_->_state_ = 2;
	rygel_external_container_create_media_objects (_data_->self, _data_->_tmp16_, _data_->_tmp16__length1, (RygelMediaContainer*) _data_->self, rygel_external_container_get_children_ready, _data_);
	return FALSE;
	_state_2:
	_data_->_tmp17_ = NULL;
	_data_->_tmp17_ = rygel_external_container_create_media_objects_finish (_data_->self, _data_->_res_, &_data_->_inner_error_);
	_data_->_result_ = _data_->_tmp17_;
	if (G_UNLIKELY (_data_->_inner_error_ != NULL)) {
		g_simple_async_result_set_from_error (_data_->_async_result, _data_->_inner_error_);
		g_error_free (_data_->_inner_error_);
		_data_->children_props = (_vala_array_free (_data_->children_props, _data_->children_props_length1, (GDestroyNotify) g_hash_table_unref), NULL);
		_data_->filter = (_vala_array_free (_data_->filter, _data_->filter_length1, (GDestroyNotify) g_free), NULL);
		if (_data_->_state_ == 0) {
			g_simple_async_result_complete_in_idle (_data_->_async_result);
		} else {
			g_simple_async_result_complete (_data_->_async_result);
		}
		g_object_unref (_data_->_async_result);
		return FALSE;
	}
	_data_->_tmp18_ = NULL;
	_data_->_tmp18_ = _data_->_result_;
	_data_->_tmp19_ = NULL;
	_data_->_tmp19_ = _data_->sort_criteria;
	rygel_media_objects_sort_by_criteria (_data_->_tmp18_, _data_->_tmp19_);
	_data_->result = _data_->_result_;
	_data_->children_props = (_vala_array_free (_data_->children_props, _data_->children_props_length1, (GDestroyNotify) g_hash_table_unref), NULL);
	_data_->filter = (_vala_array_free (_data_->filter, _data_->filter_length1, (GDestroyNotify) g_free), NULL);
	if (_data_->_state_ == 0) {
		g_simple_async_result_complete_in_idle (_data_->_async_result);
	} else {
		g_simple_async_result_complete (_data_->_async_result);
	}
	g_object_unref (_data_->_async_result);
	return FALSE;
	_g_object_unref0 (_data_->_result_);
	_data_->children_props = (_vala_array_free (_data_->children_props, _data_->children_props_length1, (GDestroyNotify) g_hash_table_unref), NULL);
	_data_->filter = (_vala_array_free (_data_->filter, _data_->filter_length1, (GDestroyNotify) g_free), NULL);
	if (_data_->_state_ == 0) {
		g_simple_async_result_complete_in_idle (_data_->_async_result);
	} else {
		g_simple_async_result_complete (_data_->_async_result);
	}
	g_object_unref (_data_->_async_result);
	return FALSE;
}


static void rygel_external_container_real_search_data_free (gpointer _data) {
	RygelExternalContainerSearchData* _data_;
	_data_ = _data;
	_rygel_search_expression_unref0 (_data_->expression);
	_g_free0 (_data_->sort_criteria);
	_g_object_unref0 (_data_->cancellable);
	_g_object_unref0 (_data_->result);
	_g_object_unref0 (_data_->self);
	g_slice_free (RygelExternalContainerSearchData, _data_);
}


static gpointer _rygel_search_expression_ref0 (gpointer self) {
	return self ? rygel_search_expression_ref (self) : NULL;
}


static void rygel_external_container_real_search (RygelSearchableContainer* base, RygelSearchExpression* expression, guint offset, guint max_count, const gchar* sort_criteria, GCancellable* cancellable, GAsyncReadyCallback _callback_, gpointer _user_data_) {
	RygelExternalContainer * self;
	RygelExternalContainerSearchData* _data_;
	RygelExternalContainer* _tmp0_ = NULL;
	RygelSearchExpression* _tmp1_ = NULL;
	RygelSearchExpression* _tmp2_ = NULL;
	guint _tmp3_ = 0U;
	guint _tmp4_ = 0U;
	const gchar* _tmp5_ = NULL;
	gchar* _tmp6_ = NULL;
	GCancellable* _tmp7_ = NULL;
	GCancellable* _tmp8_ = NULL;
	self = (RygelExternalContainer*) base;
	_data_ = g_slice_new0 (RygelExternalContainerSearchData);
	_data_->_async_result = g_simple_async_result_new (G_OBJECT (self), _callback_, _user_data_, rygel_external_container_real_search);
	g_simple_async_result_set_op_res_gpointer (_data_->_async_result, _data_, rygel_external_container_real_search_data_free);
	_tmp0_ = _g_object_ref0 (self);
	_data_->self = _tmp0_;
	_tmp1_ = expression;
	_tmp2_ = _rygel_search_expression_ref0 (_tmp1_);
	_rygel_search_expression_unref0 (_data_->expression);
	_data_->expression = _tmp2_;
	_tmp3_ = offset;
	_data_->offset = _tmp3_;
	_tmp4_ = max_count;
	_data_->max_count = _tmp4_;
	_tmp5_ = sort_criteria;
	_tmp6_ = g_strdup (_tmp5_);
	_g_free0 (_data_->sort_criteria);
	_data_->sort_criteria = _tmp6_;
	_tmp7_ = cancellable;
	_tmp8_ = _g_object_ref0 (_tmp7_);
	_g_object_unref0 (_data_->cancellable);
	_data_->cancellable = _tmp8_;
	rygel_external_container_real_search_co (_data_);
}


static RygelMediaObjects* rygel_external_container_real_search_finish (RygelSearchableContainer* base, GAsyncResult* _res_, guint* total_matches, GError** error) {
	RygelMediaObjects* result;
	RygelExternalContainerSearchData* _data_;
	if (g_simple_async_result_propagate_error (G_SIMPLE_ASYNC_RESULT (_res_), error)) {
		return NULL;
	}
	_data_ = g_simple_async_result_get_op_res_gpointer (G_SIMPLE_ASYNC_RESULT (_res_));
	if (total_matches) {
		*total_matches = _data_->total_matches;
	}
	result = _data_->result;
	_data_->result = NULL;
	return result;
}


static void rygel_external_container_search_ready (GObject* source_object, GAsyncResult* _res_, gpointer _user_data_) {
	RygelExternalContainerSearchData* _data_;
	_data_ = _user_data_;
	_data_->_source_object_ = source_object;
	_data_->_res_ = _res_;
	rygel_external_container_real_search_co (_data_);
}


static void _vala_array_add4 (gchar*** array, int* length, int* size, gchar* value) {
	if ((*length) == (*size)) {
		*size = (*size) ? (2 * (*size)) : 4;
		*array = g_renew (gchar*, *array, (*size) + 1);
	}
	(*array)[(*length)++] = value;
	(*array)[*length] = NULL;
}


static void _vala_array_add5 (gchar*** array, int* length, int* size, gchar* value) {
	if ((*length) == (*size)) {
		*size = (*size) ? (2 * (*size)) : 4;
		*array = g_renew (gchar*, *array, (*size) + 1);
	}
	(*array)[(*length)++] = value;
	(*array)[*length] = NULL;
}


static void _vala_array_add6 (gchar*** array, int* length, int* size, gchar* value) {
	if ((*length) == (*size)) {
		*size = (*size) ? (2 * (*size)) : 4;
		*array = g_renew (gchar*, *array, (*size) + 1);
	}
	(*array)[(*length)++] = value;
	(*array)[*length] = NULL;
}


static gboolean rygel_external_container_real_search_co (RygelExternalContainerSearchData* _data_) {
	switch (_data_->_state_) {
		case 0:
		goto _state_0;
		case 1:
		goto _state_1;
		case 2:
		goto _state_2;
		case 3:
		goto _state_3;
		default:
		g_assert_not_reached ();
	}
	_state_0:
	_data_->_tmp1_ = NULL;
	_data_->_tmp1_ = _data_->expression;
	if (_data_->_tmp1_ == NULL) {
		_data_->_tmp0_ = TRUE;
	} else {
		_data_->_tmp2_ = FALSE;
		_data_->_tmp2_ = _data_->self->priv->searchable;
		_data_->_tmp0_ = !_data_->_tmp2_;
	}
	if (_data_->_tmp0_) {
		_data_->_tmp4_ = NULL;
		_data_->_tmp4_ = _data_->expression;
		_data_->_tmp5_ = 0U;
		_data_->_tmp5_ = _data_->offset;
		_data_->_tmp6_ = 0U;
		_data_->_tmp6_ = _data_->max_count;
		_data_->_tmp7_ = NULL;
		_data_->_tmp7_ = _data_->sort_criteria;
		_data_->_tmp8_ = NULL;
		_data_->_tmp8_ = _data_->cancellable;
		_data_->_tmp9_ = 0U;
		_data_->_state_ = 1;
		rygel_searchable_container_simple_search ((RygelSearchableContainer*) _data_->self, _data_->_tmp4_, _data_->_tmp5_, _data_->_tmp6_, _data_->_tmp7_, _data_->_tmp8_, rygel_external_container_search_ready, _data_);
		return FALSE;
		_state_1:
		_data_->_tmp10_ = NULL;
		_data_->_tmp10_ = rygel_searchable_container_simple_search_finish ((RygelSearchableContainer*) _data_->self, _data_->_res_, &_data_->_tmp9_, &_data_->_inner_error_);
		_data_->total_matches = _data_->_tmp9_;
		_data_->_tmp3_ = _data_->_tmp10_;
		if (G_UNLIKELY (_data_->_inner_error_ != NULL)) {
			g_simple_async_result_set_from_error (_data_->_async_result, _data_->_inner_error_);
			g_error_free (_data_->_inner_error_);
			if (_data_->_state_ == 0) {
				g_simple_async_result_complete_in_idle (_data_->_async_result);
			} else {
				g_simple_async_result_complete (_data_->_async_result);
			}
			g_object_unref (_data_->_async_result);
			return FALSE;
		}
		_data_->_tmp11_ = NULL;
		_data_->_tmp11_ = _data_->_tmp3_;
		_data_->_tmp3_ = NULL;
		_data_->result = _data_->_tmp11_;
		_g_object_unref0 (_data_->_tmp3_);
		if (_data_->_state_ == 0) {
			g_simple_async_result_complete_in_idle (_data_->_async_result);
		} else {
			g_simple_async_result_complete (_data_->_async_result);
		}
		g_object_unref (_data_->_async_result);
		return FALSE;
	}
	_data_->_tmp12_ = NULL;
	_data_->_tmp12_ = g_new0 (gchar*, 0 + 1);
	_data_->filter_length1 = 0;
	_data_->_filter_size_ = 0;
	_data_->filter = _data_->_tmp12_;
	_data_->filter_length1 = 0;
	_data_->_filter_size_ = _data_->filter_length1;
	{
		_data_->object_prop_collection_length1 = 0;
		_data_->_object_prop_collection_size_ = 0;
		_data_->object_prop_collection = RYGEL_EXTERNAL_MEDIA_OBJECT_PROXY_PROPERTIES;
		_data_->object_prop_collection_length1 = G_N_ELEMENTS (RYGEL_EXTERNAL_MEDIA_OBJECT_PROXY_PROPERTIES);
		for (_data_->object_prop_it = 0; _data_->object_prop_it < G_N_ELEMENTS (RYGEL_EXTERNAL_MEDIA_OBJECT_PROXY_PROPERTIES); _data_->object_prop_it = _data_->object_prop_it + 1) {
			_data_->object_prop = _data_->object_prop_collection[_data_->object_prop_it];
			{
				_data_->_tmp13_ = NULL;
				_data_->_tmp13__length1 = 0;
				_data_->_tmp13_ = _data_->filter;
				_data_->_tmp13__length1 = _data_->filter_length1;
				_data_->_tmp14_ = NULL;
				_data_->_tmp14_ = _data_->object_prop;
				_data_->_tmp15_ = NULL;
				_data_->_tmp15_ = g_strdup (_data_->_tmp14_);
				_vala_array_add4 (&_data_->filter, &_data_->filter_length1, &_data_->_filter_size_, _data_->_tmp15_);
			}
		}
	}
	{
		_data_->container_prop_collection_length1 = 0;
		_data_->_container_prop_collection_size_ = 0;
		_data_->container_prop_collection = RYGEL_EXTERNAL_MEDIA_CONTAINER_PROXY_PROPERTIES;
		_data_->container_prop_collection_length1 = G_N_ELEMENTS (RYGEL_EXTERNAL_MEDIA_CONTAINER_PROXY_PROPERTIES);
		for (_data_->container_prop_it = 0; _data_->container_prop_it < G_N_ELEMENTS (RYGEL_EXTERNAL_MEDIA_CONTAINER_PROXY_PROPERTIES); _data_->container_prop_it = _data_->container_prop_it + 1) {
			_data_->container_prop = _data_->container_prop_collection[_data_->container_prop_it];
			{
				_data_->_tmp16_ = NULL;
				_data_->_tmp16__length1 = 0;
				_data_->_tmp16_ = _data_->filter;
				_data_->_tmp16__length1 = _data_->filter_length1;
				_data_->_tmp17_ = NULL;
				_data_->_tmp17_ = _data_->container_prop;
				_data_->_tmp18_ = NULL;
				_data_->_tmp18_ = g_strdup (_data_->_tmp17_);
				_vala_array_add5 (&_data_->filter, &_data_->filter_length1, &_data_->_filter_size_, _data_->_tmp18_);
			}
		}
	}
	{
		_data_->item_prop_collection_length1 = 0;
		_data_->_item_prop_collection_size_ = 0;
		_data_->item_prop_collection = RYGEL_EXTERNAL_MEDIA_ITEM_PROXY_PROPERTIES;
		_data_->item_prop_collection_length1 = G_N_ELEMENTS (RYGEL_EXTERNAL_MEDIA_ITEM_PROXY_PROPERTIES);
		for (_data_->item_prop_it = 0; _data_->item_prop_it < G_N_ELEMENTS (RYGEL_EXTERNAL_MEDIA_ITEM_PROXY_PROPERTIES); _data_->item_prop_it = _data_->item_prop_it + 1) {
			_data_->item_prop = _data_->item_prop_collection[_data_->item_prop_it];
			{
				_data_->_tmp19_ = NULL;
				_data_->_tmp19__length1 = 0;
				_data_->_tmp19_ = _data_->filter;
				_data_->_tmp19__length1 = _data_->filter_length1;
				_data_->_tmp20_ = NULL;
				_data_->_tmp20_ = _data_->item_prop;
				_data_->_tmp21_ = NULL;
				_data_->_tmp21_ = g_strdup (_data_->_tmp20_);
				_vala_array_add6 (&_data_->filter, &_data_->filter_length1, &_data_->_filter_size_, _data_->_tmp21_);
			}
		}
	}
	_data_->_tmp22_ = NULL;
	_data_->_tmp22_ = _data_->expression;
	_data_->_tmp23_ = NULL;
	_data_->_tmp23_ = rygel_external_container_translate_expression (_data_->self, _data_->_tmp22_);
	_data_->ext_expression = _data_->_tmp23_;
	_data_->_tmp24_ = NULL;
	_data_->_tmp24_ = _data_->self->actual_container;
	_data_->_tmp25_ = NULL;
	_data_->_tmp25_ = _data_->ext_expression;
	_data_->_tmp26_ = NULL;
	_data_->_tmp26_ = rygel_search_expression_to_string (_data_->_tmp25_);
	_data_->_tmp27_ = NULL;
	_data_->_tmp27_ = _data_->_tmp26_;
	_data_->_tmp28_ = 0U;
	_data_->_tmp28_ = _data_->offset;
	_data_->_tmp29_ = 0U;
	_data_->_tmp29_ = _data_->max_count;
	_data_->_tmp30_ = NULL;
	_data_->_tmp30__length1 = 0;
	_data_->_tmp30_ = _data_->filter;
	_data_->_tmp30__length1 = _data_->filter_length1;
	_data_->_tmp31_ = 0;
	_data_->_state_ = 2;
	rygel_external_media_container_proxy_search_objects (_data_->_tmp24_, _data_->_tmp27_, _data_->_tmp28_, _data_->_tmp29_, _data_->_tmp30_, _data_->_tmp30__length1, rygel_external_container_search_ready, _data_);
	return FALSE;
	_state_2:
	_data_->_tmp32_ = NULL;
	_data_->_tmp32_ = rygel_external_media_container_proxy_search_objects_finish (_data_->_tmp24_, _data_->_res_, &_data_->_tmp31_, &_data_->_inner_error_);
	_data_->_tmp33_ = NULL;
	_data_->_tmp33__length1 = 0;
	_data_->_tmp33_ = _data_->_tmp32_;
	_data_->_tmp33__length1 = _data_->_tmp31_;
	_g_free0 (_data_->_tmp27_);
	_data_->_result__length1 = 0;
	_data_->__result__size_ = 0;
	_data_->_result_ = _data_->_tmp33_;
	_data_->_result__length1 = _data_->_tmp33__length1;
	_data_->__result__size_ = _data_->_result__length1;
	if (G_UNLIKELY (_data_->_inner_error_ != NULL)) {
		g_simple_async_result_set_from_error (_data_->_async_result, _data_->_inner_error_);
		g_error_free (_data_->_inner_error_);
		_rygel_search_expression_unref0 (_data_->ext_expression);
		_data_->filter = (_vala_array_free (_data_->filter, _data_->filter_length1, (GDestroyNotify) g_free), NULL);
		if (_data_->_state_ == 0) {
			g_simple_async_result_complete_in_idle (_data_->_async_result);
		} else {
			g_simple_async_result_complete (_data_->_async_result);
		}
		g_object_unref (_data_->_async_result);
		return FALSE;
	}
	_data_->_tmp34_ = NULL;
	_data_->_tmp34__length1 = 0;
	_data_->_tmp34_ = _data_->_result_;
	_data_->_tmp34__length1 = _data_->_result__length1;
	_data_->total_matches = (guint) _data_->_tmp34__length1;
	_data_->_tmp35_ = NULL;
	_data_->_tmp35__length1 = 0;
	_data_->_tmp35_ = _data_->_result_;
	_data_->_tmp35__length1 = _data_->_result__length1;
	_data_->_state_ = 3;
	rygel_external_container_create_media_objects (_data_->self, _data_->_tmp35_, _data_->_tmp35__length1, NULL, rygel_external_container_search_ready, _data_);
	return FALSE;
	_state_3:
	_data_->_tmp36_ = NULL;
	_data_->_tmp36_ = rygel_external_container_create_media_objects_finish (_data_->self, _data_->_res_, &_data_->_inner_error_);
	_data_->objects = _data_->_tmp36_;
	if (G_UNLIKELY (_data_->_inner_error_ != NULL)) {
		g_simple_async_result_set_from_error (_data_->_async_result, _data_->_inner_error_);
		g_error_free (_data_->_inner_error_);
		_data_->_result_ = (_vala_array_free (_data_->_result_, _data_->_result__length1, (GDestroyNotify) g_hash_table_unref), NULL);
		_rygel_search_expression_unref0 (_data_->ext_expression);
		_data_->filter = (_vala_array_free (_data_->filter, _data_->filter_length1, (GDestroyNotify) g_free), NULL);
		if (_data_->_state_ == 0) {
			g_simple_async_result_complete_in_idle (_data_->_async_result);
		} else {
			g_simple_async_result_complete (_data_->_async_result);
		}
		g_object_unref (_data_->_async_result);
		return FALSE;
	}
	_data_->_tmp37_ = NULL;
	_data_->_tmp37_ = _data_->objects;
	_data_->_tmp38_ = NULL;
	_data_->_tmp38_ = _data_->sort_criteria;
	rygel_media_objects_sort_by_criteria (_data_->_tmp37_, _data_->_tmp38_);
	_data_->result = _data_->objects;
	_data_->_result_ = (_vala_array_free (_data_->_result_, _data_->_result__length1, (GDestroyNotify) g_hash_table_unref), NULL);
	_rygel_search_expression_unref0 (_data_->ext_expression);
	_data_->filter = (_vala_array_free (_data_->filter, _data_->filter_length1, (GDestroyNotify) g_free), NULL);
	if (_data_->_state_ == 0) {
		g_simple_async_result_complete_in_idle (_data_->_async_result);
	} else {
		g_simple_async_result_complete (_data_->_async_result);
	}
	g_object_unref (_data_->_async_result);
	return FALSE;
	_g_object_unref0 (_data_->objects);
	_data_->_result_ = (_vala_array_free (_data_->_result_, _data_->_result__length1, (GDestroyNotify) g_hash_table_unref), NULL);
	_rygel_search_expression_unref0 (_data_->ext_expression);
	_data_->filter = (_vala_array_free (_data_->filter, _data_->filter_length1, (GDestroyNotify) g_free), NULL);
	if (_data_->_state_ == 0) {
		g_simple_async_result_complete_in_idle (_data_->_async_result);
	} else {
		g_simple_async_result_complete (_data_->_async_result);
	}
	g_object_unref (_data_->_async_result);
	return FALSE;
}


static void rygel_external_container_real_find_object_data_free (gpointer _data) {
	RygelExternalContainerFindObjectData* _data_;
	_data_ = _data;
	_g_free0 (_data_->id);
	_g_object_unref0 (_data_->cancellable);
	_g_object_unref0 (_data_->result);
	_g_object_unref0 (_data_->self);
	g_slice_free (RygelExternalContainerFindObjectData, _data_);
}


static void rygel_external_container_real_find_object (RygelMediaContainer* base, const gchar* id, GCancellable* cancellable, GAsyncReadyCallback _callback_, gpointer _user_data_) {
	RygelExternalContainer * self;
	RygelExternalContainerFindObjectData* _data_;
	RygelExternalContainer* _tmp0_ = NULL;
	const gchar* _tmp1_ = NULL;
	gchar* _tmp2_ = NULL;
	GCancellable* _tmp3_ = NULL;
	GCancellable* _tmp4_ = NULL;
	self = (RygelExternalContainer*) base;
	_data_ = g_slice_new0 (RygelExternalContainerFindObjectData);
	_data_->_async_result = g_simple_async_result_new (G_OBJECT (self), _callback_, _user_data_, rygel_external_container_real_find_object);
	g_simple_async_result_set_op_res_gpointer (_data_->_async_result, _data_, rygel_external_container_real_find_object_data_free);
	_tmp0_ = _g_object_ref0 (self);
	_data_->self = _tmp0_;
	_tmp1_ = id;
	_tmp2_ = g_strdup (_tmp1_);
	_g_free0 (_data_->id);
	_data_->id = _tmp2_;
	_tmp3_ = cancellable;
	_tmp4_ = _g_object_ref0 (_tmp3_);
	_g_object_unref0 (_data_->cancellable);
	_data_->cancellable = _tmp4_;
	rygel_external_container_real_find_object_co (_data_);
}


static RygelMediaObject* rygel_external_container_real_find_object_finish (RygelMediaContainer* base, GAsyncResult* _res_, GError** error) {
	RygelMediaObject* result;
	RygelExternalContainerFindObjectData* _data_;
	if (g_simple_async_result_propagate_error (G_SIMPLE_ASYNC_RESULT (_res_), error)) {
		return NULL;
	}
	_data_ = g_simple_async_result_get_op_res_gpointer (G_SIMPLE_ASYNC_RESULT (_res_));
	result = _data_->result;
	_data_->result = NULL;
	return result;
}


static void rygel_external_container_find_object_ready (GObject* source_object, GAsyncResult* _res_, gpointer _user_data_) {
	RygelExternalContainerFindObjectData* _data_;
	_data_ = _user_data_;
	_data_->_source_object_ = source_object;
	_data_->_res_ = _res_;
	rygel_external_container_real_find_object_co (_data_);
}


static guint _variant_get1 (GVariant* value) {
	return g_variant_get_uint32 (value);
}


static gboolean _variant_get2 (GVariant* value) {
	return g_variant_get_boolean (value);
}


static gchar* _variant_get3 (GVariant* value) {
	return g_variant_dup_string (value, NULL);
}


static gboolean rygel_external_container_real_find_object_co (RygelExternalContainerFindObjectData* _data_) {
	switch (_data_->_state_) {
		case 0:
		goto _state_0;
		case 1:
		goto _state_1;
		case 2:
		goto _state_2;
		case 3:
		goto _state_3;
		case 4:
		goto _state_4;
		case 5:
		goto _state_5;
		case 6:
		goto _state_6;
		case 7:
		goto _state_7;
		case 8:
		goto _state_8;
		default:
		g_assert_not_reached ();
	}
	_state_0:
	_data_->media_object = NULL;
	_data_->_tmp0_ = NULL;
	_data_->_tmp0_ = _data_->self->service_name;
	_data_->_tmp1_ = NULL;
	_data_->_tmp1_ = _data_->id;
	_data_->_state_ = 1;
	g_async_initable_new_async (RYGEL_EXTERNAL_TYPE_MEDIA_OBJECT_PROXY_PROXY, 0, NULL, rygel_external_container_find_object_ready, _data_, "g-flags", 0, "g-name", _data_->_tmp0_, "g-bus-type", G_BUS_TYPE_SESSION, "g-object-path", _data_->_tmp1_, "g-interface-name", "org.gnome.UPnP.MediaObject2", "g-interface-info", g_type_get_qdata (RYGEL_EXTERNAL_TYPE_MEDIA_OBJECT_PROXY, g_quark_from_static_string ("vala-dbus-interface-info")), NULL);
	return FALSE;
	_state_1:
	_data_->_tmp2_ = NULL;
	_data_->_tmp2_ = g_async_initable_new_finish (_data_->_source_object_, _data_->_res_, &_data_->_inner_error_);
	_data_->actual_object = (RygelExternalMediaObjectProxy*) _data_->_tmp2_;
	if (G_UNLIKELY (_data_->_inner_error_ != NULL)) {
		g_simple_async_result_set_from_error (_data_->_async_result, _data_->_inner_error_);
		g_error_free (_data_->_inner_error_);
		_g_object_unref0 (_data_->media_object);
		if (_data_->_state_ == 0) {
			g_simple_async_result_complete_in_idle (_data_->_async_result);
		} else {
			g_simple_async_result_complete (_data_->_async_result);
		}
		g_object_unref (_data_->_async_result);
		return FALSE;
	}
	_data_->_tmp3_ = NULL;
	_data_->_tmp3_ = _data_->actual_object;
	_data_->_tmp4_ = NULL;
	_data_->_tmp4_ = rygel_external_media_object_proxy_get_object_type (_data_->_tmp3_);
	_data_->_tmp5_ = NULL;
	_data_->_tmp5_ = _data_->_tmp4_;
	_data_->_tmp6_ = NULL;
	_data_->_tmp6_ = _data_->_tmp5_;
	_data_->_tmp7_ = FALSE;
	_data_->_tmp7_ = g_strcmp0 (_data_->_tmp6_, "container") == 0;
	_g_free0 (_data_->_tmp6_);
	if (_data_->_tmp7_) {
		_data_->_tmp8_ = NULL;
		_data_->_tmp8_ = _data_->id;
		_data_->_tmp9_ = NULL;
		_data_->_tmp9_ = rygel_external_container_find_container_by_id (_data_->self, _data_->_tmp8_);
		_g_object_unref0 (_data_->media_object);
		_data_->media_object = (RygelMediaObject*) _data_->_tmp9_;
		_data_->_tmp10_ = NULL;
		_data_->_tmp10_ = _data_->media_object;
		if (_data_->_tmp10_ == NULL) {
			{
				_data_->_tmp11_ = NULL;
				_data_->_tmp11_ = _data_->self->priv->containers;
				_data_->_tmp12_ = NULL;
				_data_->_tmp12_ = _g_object_ref0 (_data_->_tmp11_);
				_data_->_container_list = _data_->_tmp12_;
				_data_->_tmp13_ = NULL;
				_data_->_tmp13_ = _data_->_container_list;
				_data_->_tmp14_ = 0;
				_data_->_tmp14_ = gee_abstract_collection_get_size ((GeeCollection*) _data_->_tmp13_);
				_data_->_tmp15_ = 0;
				_data_->_tmp15_ = _data_->_tmp14_;
				_data_->_container_size = _data_->_tmp15_;
				_data_->_container_index = -1;
				while (TRUE) {
					_data_->_tmp16_ = 0;
					_data_->_tmp16_ = _data_->_container_index;
					_data_->_container_index = _data_->_tmp16_ + 1;
					_data_->_tmp17_ = 0;
					_data_->_tmp17_ = _data_->_container_index;
					_data_->_tmp18_ = 0;
					_data_->_tmp18_ = _data_->_container_size;
					if (!(_data_->_tmp17_ < _data_->_tmp18_)) {
						break;
					}
					_data_->_tmp19_ = NULL;
					_data_->_tmp19_ = _data_->_container_list;
					_data_->_tmp20_ = 0;
					_data_->_tmp20_ = _data_->_container_index;
					_data_->_tmp21_ = NULL;
					_data_->_tmp21_ = gee_abstract_list_get ((GeeAbstractList*) _data_->_tmp19_, _data_->_tmp20_);
					_data_->container = (RygelExternalContainer*) _data_->_tmp21_;
					_data_->_tmp23_ = NULL;
					_data_->_tmp23_ = _data_->container;
					_data_->_tmp24_ = NULL;
					_data_->_tmp24_ = _data_->id;
					_data_->_tmp25_ = NULL;
					_data_->_tmp25_ = _data_->cancellable;
					_data_->_state_ = 2;
					rygel_media_container_find_object ((RygelMediaContainer*) _data_->_tmp23_, _data_->_tmp24_, _data_->_tmp25_, rygel_external_container_find_object_ready, _data_);
					return FALSE;
					_state_2:
					_data_->_tmp26_ = NULL;
					_data_->_tmp26_ = rygel_media_container_find_object_finish ((RygelMediaContainer*) _data_->_tmp23_, _data_->_res_, &_data_->_inner_error_);
					_data_->_tmp22_ = _data_->_tmp26_;
					if (G_UNLIKELY (_data_->_inner_error_ != NULL)) {
						g_simple_async_result_set_from_error (_data_->_async_result, _data_->_inner_error_);
						g_error_free (_data_->_inner_error_);
						_g_object_unref0 (_data_->container);
						_g_object_unref0 (_data_->_container_list);
						_g_object_unref0 (_data_->actual_object);
						_g_object_unref0 (_data_->media_object);
						if (_data_->_state_ == 0) {
							g_simple_async_result_complete_in_idle (_data_->_async_result);
						} else {
							g_simple_async_result_complete (_data_->_async_result);
						}
						g_object_unref (_data_->_async_result);
						return FALSE;
					}
					_data_->_tmp27_ = NULL;
					_data_->_tmp27_ = _data_->_tmp22_;
					_data_->_tmp22_ = NULL;
					_g_object_unref0 (_data_->media_object);
					_data_->media_object = _data_->_tmp27_;
					_data_->_tmp28_ = NULL;
					_data_->_tmp28_ = _data_->media_object;
					if (_data_->_tmp28_ != NULL) {
						_g_object_unref0 (_data_->_tmp22_);
						_g_object_unref0 (_data_->container);
						break;
					}
					_g_object_unref0 (_data_->_tmp22_);
					_g_object_unref0 (_data_->container);
				}
				_g_object_unref0 (_data_->_container_list);
			}
			_data_->_tmp29_ = NULL;
			_data_->_tmp29_ = _data_->self->service_name;
			_data_->_tmp30_ = NULL;
			_data_->_tmp30_ = _data_->id;
			_data_->_state_ = 3;
			g_async_initable_new_async (RYGEL_EXTERNAL_FREE_DESKTOP_TYPE_PROPERTIES_PROXY, 0, NULL, rygel_external_container_find_object_ready, _data_, "g-flags", G_DBUS_PROXY_FLAGS_DO_NOT_LOAD_PROPERTIES, "g-name", _data_->_tmp29_, "g-bus-type", G_BUS_TYPE_SESSION, "g-object-path", _data_->_tmp30_, "g-interface-name", "org.freedesktop.DBus.Properties", "g-interface-info", g_type_get_qdata (RYGEL_EXTERNAL_FREE_DESKTOP_TYPE_PROPERTIES, g_quark_from_static_string ("vala-dbus-interface-info")), NULL);
			return FALSE;
			_state_3:
			_data_->_tmp31_ = NULL;
			_data_->_tmp31_ = g_async_initable_new_finish (_data_->_source_object_, _data_->_res_, &_data_->_inner_error_);
			_data_->props_iface = (RygelExternalFreeDesktopProperties*) _data_->_tmp31_;
			if (G_UNLIKELY (_data_->_inner_error_ != NULL)) {
				g_simple_async_result_set_from_error (_data_->_async_result, _data_->_inner_error_);
				g_error_free (_data_->_inner_error_);
				_g_object_unref0 (_data_->actual_object);
				_g_object_unref0 (_data_->media_object);
				if (_data_->_state_ == 0) {
					g_simple_async_result_complete_in_idle (_data_->_async_result);
				} else {
					g_simple_async_result_complete (_data_->_async_result);
				}
				g_object_unref (_data_->_async_result);
				return FALSE;
			}
			_data_->_tmp32_ = NULL;
			_data_->_tmp32_ = _data_->props_iface;
			_data_->_state_ = 4;
			rygel_external_free_desktop_properties_get_all (_data_->_tmp32_, RYGEL_EXTERNAL_MEDIA_CONTAINER_PROXY_IFACE, rygel_external_container_find_object_ready, _data_);
			return FALSE;
			_state_4:
			_data_->_tmp33_ = NULL;
			_data_->_tmp33_ = rygel_external_free_desktop_properties_get_all_finish (_data_->_tmp32_, _data_->_res_, &_data_->_inner_error_);
			_data_->props = _data_->_tmp33_;
			if (G_UNLIKELY (_data_->_inner_error_ != NULL)) {
				g_simple_async_result_set_from_error (_data_->_async_result, _data_->_inner_error_);
				g_error_free (_data_->_inner_error_);
				_g_object_unref0 (_data_->props_iface);
				_g_object_unref0 (_data_->actual_object);
				_g_object_unref0 (_data_->media_object);
				if (_data_->_state_ == 0) {
					g_simple_async_result_complete_in_idle (_data_->_async_result);
				} else {
					g_simple_async_result_complete (_data_->_async_result);
				}
				g_object_unref (_data_->_async_result);
				return FALSE;
			}
			_data_->_tmp34_ = NULL;
			_data_->_tmp34_ = _data_->props;
			_data_->_tmp35_ = NULL;
			_data_->_tmp35_ = g_hash_table_lookup (_data_->_tmp34_, "ChildCount");
			_data_->_tmp36_ = 0U;
			_data_->_tmp36_ = _variant_get1 ((GVariant*) _data_->_tmp35_);
			_data_->child_count = _data_->_tmp36_;
			_data_->_tmp37_ = NULL;
			_data_->_tmp37_ = _data_->props;
			_data_->_tmp38_ = NULL;
			_data_->_tmp38_ = g_hash_table_lookup (_data_->_tmp37_, "Searchable");
			_data_->_tmp39_ = FALSE;
			_data_->_tmp39_ = _variant_get2 ((GVariant*) _data_->_tmp38_);
			_data_->searchable = _data_->_tmp39_;
			_data_->_tmp41_ = NULL;
			_data_->_tmp41_ = _data_->props_iface;
			_data_->_state_ = 5;
			rygel_external_free_desktop_properties_get_all (_data_->_tmp41_, RYGEL_EXTERNAL_MEDIA_OBJECT_PROXY_IFACE, rygel_external_container_find_object_ready, _data_);
			return FALSE;
			_state_5:
			_data_->_tmp42_ = NULL;
			_data_->_tmp42_ = rygel_external_free_desktop_properties_get_all_finish (_data_->_tmp41_, _data_->_res_, &_data_->_inner_error_);
			_data_->_tmp40_ = _data_->_tmp42_;
			if (G_UNLIKELY (_data_->_inner_error_ != NULL)) {
				g_simple_async_result_set_from_error (_data_->_async_result, _data_->_inner_error_);
				g_error_free (_data_->_inner_error_);
				_g_hash_table_unref0 (_data_->props);
				_g_object_unref0 (_data_->props_iface);
				_g_object_unref0 (_data_->actual_object);
				_g_object_unref0 (_data_->media_object);
				if (_data_->_state_ == 0) {
					g_simple_async_result_complete_in_idle (_data_->_async_result);
				} else {
					g_simple_async_result_complete (_data_->_async_result);
				}
				g_object_unref (_data_->_async_result);
				return FALSE;
			}
			_data_->_tmp43_ = NULL;
			_data_->_tmp43_ = _data_->_tmp40_;
			_data_->_tmp40_ = NULL;
			_g_hash_table_unref0 (_data_->props);
			_data_->props = _data_->_tmp43_;
			_data_->_tmp44_ = NULL;
			_data_->_tmp44_ = _data_->props;
			_data_->_tmp45_ = NULL;
			_data_->_tmp45_ = g_hash_table_lookup (_data_->_tmp44_, "Path");
			_data_->_tmp46_ = NULL;
			_data_->_tmp46_ = _variant_get3 ((GVariant*) _data_->_tmp45_);
			_data_->path = _data_->_tmp46_;
			_data_->_tmp47_ = NULL;
			_data_->_tmp47_ = _data_->props;
			_data_->_tmp48_ = NULL;
			_data_->_tmp48_ = _data_->path;
			_data_->_tmp49_ = NULL;
			_data_->_tmp49_ = _data_->self->service_name;
			_data_->_tmp50_ = NULL;
			_data_->_tmp50_ = rygel_external_get_mandatory_string_value (_data_->_tmp47_, "DisplayName", _data_->_tmp48_, _data_->_tmp49_);
			_data_->title = _data_->_tmp50_;
			_data_->_tmp52_ = NULL;
			_data_->_tmp52_ = _data_->path;
			_data_->_tmp53_ = NULL;
			_data_->_tmp53_ = _data_->title;
			_data_->_tmp54_ = 0U;
			_data_->_tmp54_ = _data_->child_count;
			_data_->_tmp55_ = FALSE;
			_data_->_tmp55_ = _data_->searchable;
			_data_->_tmp56_ = NULL;
			_data_->_tmp56_ = _data_->self->service_name;
			_data_->_tmp57_ = NULL;
			_data_->_tmp57_ = _data_->path;
			_data_->_tmp58_ = NULL;
			_data_->_tmp58_ = rygel_external_container_new (_data_->_tmp52_, _data_->_tmp53_, _data_->_tmp54_, _data_->_tmp55_, _data_->_tmp56_, _data_->_tmp57_, _data_->self, &_data_->_inner_error_);
			_data_->_tmp51_ = _data_->_tmp58_;
			if (G_UNLIKELY (_data_->_inner_error_ != NULL)) {
				g_simple_async_result_set_from_error (_data_->_async_result, _data_->_inner_error_);
				g_error_free (_data_->_inner_error_);
				_g_free0 (_data_->title);
				_g_free0 (_data_->path);
				_g_hash_table_unref0 (_data_->_tmp40_);
				_g_hash_table_unref0 (_data_->props);
				_g_object_unref0 (_data_->props_iface);
				_g_object_unref0 (_data_->actual_object);
				_g_object_unref0 (_data_->media_object);
				if (_data_->_state_ == 0) {
					g_simple_async_result_complete_in_idle (_data_->_async_result);
				} else {
					g_simple_async_result_complete (_data_->_async_result);
				}
				g_object_unref (_data_->_async_result);
				return FALSE;
			}
			_data_->_tmp59_ = NULL;
			_data_->_tmp59_ = _data_->_tmp51_;
			_data_->_tmp51_ = NULL;
			_g_object_unref0 (_data_->media_object);
			_data_->media_object = (RygelMediaObject*) _data_->_tmp59_;
			_g_object_unref0 (_data_->_tmp51_);
			_g_free0 (_data_->title);
			_g_free0 (_data_->path);
			_g_hash_table_unref0 (_data_->_tmp40_);
			_g_hash_table_unref0 (_data_->props);
			_g_object_unref0 (_data_->props_iface);
		}
	} else {
		_data_->_tmp60_ = NULL;
		_data_->_tmp60_ = _data_->actual_object;
		_data_->_tmp61_ = NULL;
		_data_->_tmp61_ = rygel_external_media_object_proxy_get_parent (_data_->_tmp60_);
		_data_->_tmp62_ = NULL;
		_data_->_tmp62_ = _data_->_tmp61_;
		_data_->_tmp63_ = NULL;
		_data_->_tmp63_ = (gchar*) _data_->_tmp62_;
		_data_->_tmp64_ = NULL;
		_data_->_tmp64_ = rygel_external_dummy_container_new (_data_->_tmp63_, "LaLaLa", (guint) 0, NULL);
		_data_->_tmp65_ = NULL;
		_data_->_tmp65_ = _data_->_tmp64_;
		_g_free0 (_data_->_tmp63_);
		_data_->parent_container = _data_->_tmp65_;
		_data_->_tmp66_ = NULL;
		_data_->_tmp66_ = _data_->self->service_name;
		_data_->_tmp67_ = NULL;
		_data_->_tmp67_ = _data_->id;
		_data_->_state_ = 6;
		g_async_initable_new_async (RYGEL_EXTERNAL_FREE_DESKTOP_TYPE_PROPERTIES_PROXY, 0, NULL, rygel_external_container_find_object_ready, _data_, "g-flags", G_DBUS_PROXY_FLAGS_DO_NOT_LOAD_PROPERTIES, "g-name", _data_->_tmp66_, "g-bus-type", G_BUS_TYPE_SESSION, "g-object-path", _data_->_tmp67_, "g-interface-name", "org.freedesktop.DBus.Properties", "g-interface-info", g_type_get_qdata (RYGEL_EXTERNAL_FREE_DESKTOP_TYPE_PROPERTIES, g_quark_from_static_string ("vala-dbus-interface-info")), NULL);
		return FALSE;
		_state_6:
		_data_->_tmp68_ = NULL;
		_data_->_tmp68_ = g_async_initable_new_finish (_data_->_source_object_, _data_->_res_, &_data_->_inner_error_);
		_data_->_vala1_props_iface = (RygelExternalFreeDesktopProperties*) _data_->_tmp68_;
		if (G_UNLIKELY (_data_->_inner_error_ != NULL)) {
			g_simple_async_result_set_from_error (_data_->_async_result, _data_->_inner_error_);
			g_error_free (_data_->_inner_error_);
			_g_object_unref0 (_data_->parent_container);
			_g_object_unref0 (_data_->actual_object);
			_g_object_unref0 (_data_->media_object);
			if (_data_->_state_ == 0) {
				g_simple_async_result_complete_in_idle (_data_->_async_result);
			} else {
				g_simple_async_result_complete (_data_->_async_result);
			}
			g_object_unref (_data_->_async_result);
			return FALSE;
		}
		_data_->_tmp69_ = NULL;
		_data_->_tmp69_ = _data_->_vala1_props_iface;
		_data_->_state_ = 7;
		rygel_external_free_desktop_properties_get_all (_data_->_tmp69_, RYGEL_EXTERNAL_MEDIA_ITEM_PROXY_IFACE, rygel_external_container_find_object_ready, _data_);
		return FALSE;
		_state_7:
		_data_->_tmp70_ = NULL;
		_data_->_tmp70_ = rygel_external_free_desktop_properties_get_all_finish (_data_->_tmp69_, _data_->_res_, &_data_->_inner_error_);
		_data_->_vala1_props = _data_->_tmp70_;
		if (G_UNLIKELY (_data_->_inner_error_ != NULL)) {
			g_simple_async_result_set_from_error (_data_->_async_result, _data_->_inner_error_);
			g_error_free (_data_->_inner_error_);
			_g_object_unref0 (_data_->_vala1_props_iface);
			_g_object_unref0 (_data_->parent_container);
			_g_object_unref0 (_data_->actual_object);
			_g_object_unref0 (_data_->media_object);
			if (_data_->_state_ == 0) {
				g_simple_async_result_complete_in_idle (_data_->_async_result);
			} else {
				g_simple_async_result_complete (_data_->_async_result);
			}
			g_object_unref (_data_->_async_result);
			return FALSE;
		}
		_data_->_tmp72_ = NULL;
		_data_->_tmp72_ = _data_->self->priv->item_factory;
		_data_->_tmp73_ = NULL;
		_data_->_tmp73_ = _data_->id;
		_data_->_tmp74_ = NULL;
		_data_->_tmp74_ = _data_->actual_object;
		_data_->_tmp75_ = NULL;
		_data_->_tmp75_ = rygel_external_media_object_proxy_get_object_type (_data_->_tmp74_);
		_data_->_tmp76_ = NULL;
		_data_->_tmp76_ = _data_->_tmp75_;
		_data_->_tmp77_ = NULL;
		_data_->_tmp77_ = _data_->_tmp76_;
		_data_->_tmp78_ = NULL;
		_data_->_tmp78_ = _data_->actual_object;
		_data_->_tmp79_ = NULL;
		_data_->_tmp79_ = rygel_external_media_object_proxy_get_display_name (_data_->_tmp78_);
		_data_->_tmp80_ = NULL;
		_data_->_tmp80_ = _data_->_tmp79_;
		_data_->_tmp81_ = NULL;
		_data_->_tmp81_ = _data_->_tmp80_;
		_data_->_tmp82_ = NULL;
		_data_->_tmp82_ = _data_->_vala1_props;
		_data_->_tmp83_ = NULL;
		_data_->_tmp83_ = _data_->self->service_name;
		_data_->_tmp84_ = NULL;
		_data_->_tmp84_ = _data_->parent_container;
		_data_->_state_ = 8;
		rygel_external_item_factory_create (_data_->_tmp72_, _data_->_tmp73_, _data_->_tmp77_, _data_->_tmp81_, _data_->_tmp82_, _data_->_tmp83_, (RygelMediaContainer*) _data_->_tmp84_, rygel_external_container_find_object_ready, _data_);
		return FALSE;
		_state_8:
		_data_->_tmp85_ = NULL;
		_data_->_tmp85_ = rygel_external_item_factory_create_finish (_data_->_tmp72_, _data_->_res_, &_data_->_inner_error_);
		_data_->_tmp86_ = NULL;
		_data_->_tmp86_ = _data_->_tmp85_;
		_g_free0 (_data_->_tmp81_);
		_g_free0 (_data_->_tmp77_);
		_data_->_tmp71_ = _data_->_tmp86_;
		if (G_UNLIKELY (_data_->_inner_error_ != NULL)) {
			g_simple_async_result_set_from_error (_data_->_async_result, _data_->_inner_error_);
			g_error_free (_data_->_inner_error_);
			_g_hash_table_unref0 (_data_->_vala1_props);
			_g_object_unref0 (_data_->_vala1_props_iface);
			_g_object_unref0 (_data_->parent_container);
			_g_object_unref0 (_data_->actual_object);
			_g_object_unref0 (_data_->media_object);
			if (_data_->_state_ == 0) {
				g_simple_async_result_complete_in_idle (_data_->_async_result);
			} else {
				g_simple_async_result_complete (_data_->_async_result);
			}
			g_object_unref (_data_->_async_result);
			return FALSE;
		}
		_data_->_tmp87_ = NULL;
		_data_->_tmp87_ = _data_->_tmp71_;
		_data_->_tmp71_ = NULL;
		_g_object_unref0 (_data_->media_object);
		_data_->media_object = (RygelMediaObject*) _data_->_tmp87_;
		_g_object_unref0 (_data_->_tmp71_);
		_g_hash_table_unref0 (_data_->_vala1_props);
		_g_object_unref0 (_data_->_vala1_props_iface);
		_g_object_unref0 (_data_->parent_container);
	}
	_data_->result = _data_->media_object;
	_g_object_unref0 (_data_->actual_object);
	if (_data_->_state_ == 0) {
		g_simple_async_result_complete_in_idle (_data_->_async_result);
	} else {
		g_simple_async_result_complete (_data_->_async_result);
	}
	g_object_unref (_data_->_async_result);
	return FALSE;
	_g_object_unref0 (_data_->actual_object);
	_g_object_unref0 (_data_->media_object);
	if (_data_->_state_ == 0) {
		g_simple_async_result_complete_in_idle (_data_->_async_result);
	} else {
		g_simple_async_result_complete (_data_->_async_result);
	}
	g_object_unref (_data_->_async_result);
	return FALSE;
}


static void rygel_external_container_create_media_objects_data_free (gpointer _data) {
	RygelExternalContainerCreateMediaObjectsData* _data_;
	_data_ = _data;
	_g_object_unref0 (_data_->parent);
	_g_object_unref0 (_data_->result);
	_g_object_unref0 (_data_->self);
	g_slice_free (RygelExternalContainerCreateMediaObjectsData, _data_);
}


static void rygel_external_container_create_media_objects (RygelExternalContainer* self, GHashTable** all_props, int all_props_length1, RygelMediaContainer* parent, GAsyncReadyCallback _callback_, gpointer _user_data_) {
	RygelExternalContainerCreateMediaObjectsData* _data_;
	RygelExternalContainer* _tmp0_ = NULL;
	GHashTable** _tmp1_ = NULL;
	gint _tmp1__length1 = 0;
	RygelMediaContainer* _tmp2_ = NULL;
	RygelMediaContainer* _tmp3_ = NULL;
	_data_ = g_slice_new0 (RygelExternalContainerCreateMediaObjectsData);
	_data_->_async_result = g_simple_async_result_new (G_OBJECT (self), _callback_, _user_data_, rygel_external_container_create_media_objects);
	g_simple_async_result_set_op_res_gpointer (_data_->_async_result, _data_, rygel_external_container_create_media_objects_data_free);
	_tmp0_ = _g_object_ref0 (self);
	_data_->self = _tmp0_;
	_tmp1_ = all_props;
	_tmp1__length1 = all_props_length1;
	_data_->all_props = _tmp1_;
	_data_->all_props_length1 = _tmp1__length1;
	_tmp2_ = parent;
	_tmp3_ = _g_object_ref0 (_tmp2_);
	_g_object_unref0 (_data_->parent);
	_data_->parent = _tmp3_;
	rygel_external_container_create_media_objects_co (_data_);
}


static RygelMediaObjects* rygel_external_container_create_media_objects_finish (RygelExternalContainer* self, GAsyncResult* _res_, GError** error) {
	RygelMediaObjects* result;
	RygelExternalContainerCreateMediaObjectsData* _data_;
	if (g_simple_async_result_propagate_error (G_SIMPLE_ASYNC_RESULT (_res_), error)) {
		return NULL;
	}
	_data_ = g_simple_async_result_get_op_res_gpointer (G_SIMPLE_ASYNC_RESULT (_res_));
	result = _data_->result;
	_data_->result = NULL;
	return result;
}


static gpointer _g_hash_table_ref0 (gpointer self) {
	return self ? g_hash_table_ref (self) : NULL;
}


static gchar* _variant_get4 (GVariant* value) {
	return g_variant_dup_string (value, NULL);
}


static gchar* _variant_get5 (GVariant* value) {
	return g_variant_dup_string (value, NULL);
}


static gchar* _variant_get6 (GVariant* value) {
	return g_variant_dup_string (value, NULL);
}


static guint _variant_get7 (GVariant* value) {
	return g_variant_get_uint32 (value);
}


static void rygel_external_container_create_media_objects_ready (GObject* source_object, GAsyncResult* _res_, gpointer _user_data_) {
	RygelExternalContainerCreateMediaObjectsData* _data_;
	_data_ = _user_data_;
	_data_->_source_object_ = source_object;
	_data_->_res_ = _res_;
	rygel_external_container_create_media_objects_co (_data_);
}


static gboolean rygel_external_container_create_media_objects_co (RygelExternalContainerCreateMediaObjectsData* _data_) {
	switch (_data_->_state_) {
		case 0:
		goto _state_0;
		case 1:
		goto _state_1;
		default:
		g_assert_not_reached ();
	}
	_state_0:
	_data_->_tmp0_ = NULL;
	_data_->_tmp0_ = rygel_media_objects_new ();
	_data_->media_objects = _data_->_tmp0_;
	_data_->_tmp1_ = NULL;
	_data_->_tmp1__length1 = 0;
	_data_->_tmp1_ = _data_->all_props;
	_data_->_tmp1__length1 = _data_->all_props_length1;
	{
		_data_->props_collection_length1 = 0;
		_data_->_props_collection_size_ = 0;
		_data_->props_collection = _data_->_tmp1_;
		_data_->props_collection_length1 = _data_->_tmp1__length1;
		for (_data_->props_it = 0; _data_->props_it < _data_->_tmp1__length1; _data_->props_it = _data_->props_it + 1) {
			_data_->_tmp2_ = NULL;
			_data_->_tmp2_ = _g_hash_table_ref0 (_data_->props_collection[_data_->props_it]);
			_data_->props = _data_->_tmp2_;
			{
				_data_->_tmp3_ = NULL;
				_data_->_tmp3_ = _data_->props;
				_data_->_tmp4_ = NULL;
				_data_->_tmp4_ = g_hash_table_lookup (_data_->_tmp3_, "Path");
				_data_->_tmp5_ = NULL;
				_data_->_tmp5_ = _variant_get4 ((GVariant*) _data_->_tmp4_);
				_data_->id = _data_->_tmp5_;
				_data_->_tmp6_ = NULL;
				_data_->_tmp6_ = _data_->props;
				_data_->_tmp7_ = NULL;
				_data_->_tmp7_ = g_hash_table_lookup (_data_->_tmp6_, "Type");
				_data_->_tmp8_ = NULL;
				_data_->_tmp8_ = _variant_get5 ((GVariant*) _data_->_tmp7_);
				_data_->type = _data_->_tmp8_;
				_data_->_tmp9_ = NULL;
				_data_->_tmp9_ = _data_->parent;
				if (_data_->_tmp9_ != NULL) {
					_data_->_tmp10_ = NULL;
					_data_->_tmp10_ = _data_->parent;
					_data_->_tmp11_ = NULL;
					_data_->_tmp11_ = _g_object_ref0 (_data_->_tmp10_);
					_g_object_unref0 (_data_->parent_container);
					_data_->parent_container = _data_->_tmp11_;
				} else {
					_data_->_tmp12_ = NULL;
					_data_->_tmp12_ = _data_->props;
					_data_->_tmp13_ = NULL;
					_data_->_tmp13_ = g_hash_table_lookup (_data_->_tmp12_, "Parent");
					_data_->_tmp14_ = NULL;
					_data_->_tmp14_ = _variant_get6 ((GVariant*) _data_->_tmp13_);
					_data_->parent_id = _data_->_tmp14_;
					_data_->_tmp15_ = NULL;
					_data_->_tmp15_ = _data_->parent_id;
					_data_->_tmp16_ = NULL;
					_data_->_tmp16_ = rygel_external_dummy_container_new (_data_->_tmp15_, "LaLaLa", (guint) 0, NULL);
					_g_object_unref0 (_data_->parent_container);
					_data_->parent_container = (RygelMediaContainer*) _data_->_tmp16_;
					_g_free0 (_data_->parent_id);
				}
				_data_->media_object = NULL;
				_data_->_tmp17_ = NULL;
				_data_->_tmp17_ = _data_->type;
				if (g_strcmp0 (_data_->_tmp17_, "container") == 0) {
					_data_->_tmp18_ = NULL;
					_data_->_tmp18_ = _data_->id;
					_data_->_tmp19_ = NULL;
					_data_->_tmp19_ = rygel_external_container_find_container_by_id (_data_->self, _data_->_tmp18_);
					_g_object_unref0 (_data_->media_object);
					_data_->media_object = (RygelMediaObject*) _data_->_tmp19_;
				}
				_data_->_tmp20_ = NULL;
				_data_->_tmp20_ = _data_->media_object;
				if (_data_->_tmp20_ == NULL) {
					_data_->_tmp21_ = NULL;
					_data_->_tmp21_ = _data_->props;
					_data_->_tmp22_ = NULL;
					_data_->_tmp22_ = _data_->id;
					_data_->_tmp23_ = NULL;
					_data_->_tmp23_ = _data_->self->service_name;
					_data_->_tmp24_ = NULL;
					_data_->_tmp24_ = rygel_external_get_mandatory_string_value (_data_->_tmp21_, "DisplayName", _data_->_tmp22_, _data_->_tmp23_);
					_data_->title = _data_->_tmp24_;
					_data_->_tmp25_ = NULL;
					_data_->_tmp25_ = _data_->type;
					if (g_strcmp0 (_data_->_tmp25_, "container") == 0) {
						_data_->_tmp26_ = NULL;
						_data_->_tmp26_ = _data_->props;
						_data_->_tmp27_ = NULL;
						_data_->_tmp27_ = g_hash_table_lookup (_data_->_tmp26_, "ChildCount");
						_data_->_tmp28_ = 0U;
						_data_->_tmp28_ = _variant_get7 ((GVariant*) _data_->_tmp27_);
						_data_->child_count = _data_->_tmp28_;
						_data_->_tmp29_ = NULL;
						_data_->_tmp29_ = _data_->id;
						_data_->_tmp30_ = NULL;
						_data_->_tmp30_ = _data_->title;
						_data_->_tmp31_ = 0U;
						_data_->_tmp31_ = _data_->child_count;
						_data_->_tmp32_ = NULL;
						_data_->_tmp32_ = _data_->parent_container;
						_data_->_tmp33_ = NULL;
						_data_->_tmp33_ = rygel_external_dummy_container_new (_data_->_tmp29_, _data_->_tmp30_, _data_->_tmp31_, _data_->_tmp32_);
						_g_object_unref0 (_data_->media_object);
						_data_->media_object = (RygelMediaObject*) _data_->_tmp33_;
					} else {
						_data_->_tmp35_ = NULL;
						_data_->_tmp35_ = _data_->self->priv->item_factory;
						_data_->_tmp36_ = NULL;
						_data_->_tmp36_ = _data_->id;
						_data_->_tmp37_ = NULL;
						_data_->_tmp37_ = _data_->type;
						_data_->_tmp38_ = NULL;
						_data_->_tmp38_ = _data_->title;
						_data_->_tmp39_ = NULL;
						_data_->_tmp39_ = _data_->props;
						_data_->_tmp40_ = NULL;
						_data_->_tmp40_ = _data_->self->service_name;
						_data_->_tmp41_ = NULL;
						_data_->_tmp41_ = _data_->parent_container;
						_data_->_state_ = 1;
						rygel_external_item_factory_create (_data_->_tmp35_, _data_->_tmp36_, _data_->_tmp37_, _data_->_tmp38_, _data_->_tmp39_, _data_->_tmp40_, _data_->_tmp41_, rygel_external_container_create_media_objects_ready, _data_);
						return FALSE;
						_state_1:
						_data_->_tmp42_ = NULL;
						_data_->_tmp42_ = rygel_external_item_factory_create_finish (_data_->_tmp35_, _data_->_res_, &_data_->_inner_error_);
						_data_->_tmp34_ = _data_->_tmp42_;
						if (G_UNLIKELY (_data_->_inner_error_ != NULL)) {
							g_simple_async_result_set_from_error (_data_->_async_result, _data_->_inner_error_);
							g_error_free (_data_->_inner_error_);
							_g_free0 (_data_->title);
							_g_object_unref0 (_data_->media_object);
							_g_object_unref0 (_data_->parent_container);
							_g_free0 (_data_->type);
							_g_free0 (_data_->id);
							_g_hash_table_unref0 (_data_->props);
							_g_object_unref0 (_data_->media_objects);
							if (_data_->_state_ == 0) {
								g_simple_async_result_complete_in_idle (_data_->_async_result);
							} else {
								g_simple_async_result_complete (_data_->_async_result);
							}
							g_object_unref (_data_->_async_result);
							return FALSE;
						}
						_data_->_tmp43_ = NULL;
						_data_->_tmp43_ = _data_->_tmp34_;
						_data_->_tmp34_ = NULL;
						_g_object_unref0 (_data_->media_object);
						_data_->media_object = (RygelMediaObject*) _data_->_tmp43_;
						_g_object_unref0 (_data_->_tmp34_);
					}
					_g_free0 (_data_->title);
				}
				_data_->_tmp44_ = NULL;
				_data_->_tmp44_ = _data_->media_objects;
				_data_->_tmp45_ = NULL;
				_data_->_tmp45_ = _data_->media_object;
				gee_abstract_collection_add ((GeeAbstractCollection*) _data_->_tmp44_, _data_->_tmp45_);
				_g_object_unref0 (_data_->media_object);
				_g_object_unref0 (_data_->parent_container);
				_g_free0 (_data_->type);
				_g_free0 (_data_->id);
				_g_hash_table_unref0 (_data_->props);
			}
		}
	}
	_data_->result = _data_->media_objects;
	if (_data_->_state_ == 0) {
		g_simple_async_result_complete_in_idle (_data_->_async_result);
	} else {
		g_simple_async_result_complete (_data_->_async_result);
	}
	g_object_unref (_data_->_async_result);
	return FALSE;
	_g_object_unref0 (_data_->media_objects);
	if (_data_->_state_ == 0) {
		g_simple_async_result_complete_in_idle (_data_->_async_result);
	} else {
		g_simple_async_result_complete (_data_->_async_result);
	}
	g_object_unref (_data_->_async_result);
	return FALSE;
}


static void rygel_external_container_refresh_child_containers_data_free (gpointer _data) {
	RygelExternalContainerRefreshChildContainersData* _data_;
	_data_ = _data;
	_g_object_unref0 (_data_->self);
	g_slice_free (RygelExternalContainerRefreshChildContainersData, _data_);
}


static void rygel_external_container_refresh_child_containers (RygelExternalContainer* self, GAsyncReadyCallback _callback_, gpointer _user_data_) {
	RygelExternalContainerRefreshChildContainersData* _data_;
	RygelExternalContainer* _tmp0_ = NULL;
	_data_ = g_slice_new0 (RygelExternalContainerRefreshChildContainersData);
	_data_->_async_result = g_simple_async_result_new (G_OBJECT (self), _callback_, _user_data_, rygel_external_container_refresh_child_containers);
	g_simple_async_result_set_op_res_gpointer (_data_->_async_result, _data_, rygel_external_container_refresh_child_containers_data_free);
	_tmp0_ = _g_object_ref0 (self);
	_data_->self = _tmp0_;
	rygel_external_container_refresh_child_containers_co (_data_);
}


static void rygel_external_container_refresh_child_containers_finish (RygelExternalContainer* self, GAsyncResult* _res_, GError** error) {
	RygelExternalContainerRefreshChildContainersData* _data_;
	if (g_simple_async_result_propagate_error (G_SIMPLE_ASYNC_RESULT (_res_), error)) {
		return;
	}
	_data_ = g_simple_async_result_get_op_res_gpointer (G_SIMPLE_ASYNC_RESULT (_res_));
}


static void _vala_array_add7 (gchar*** array, int* length, int* size, gchar* value) {
	if ((*length) == (*size)) {
		*size = (*size) ? (2 * (*size)) : 4;
		*array = g_renew (gchar*, *array, (*size) + 1);
	}
	(*array)[(*length)++] = value;
	(*array)[*length] = NULL;
}


static void _vala_array_add8 (gchar*** array, int* length, int* size, gchar* value) {
	if ((*length) == (*size)) {
		*size = (*size) ? (2 * (*size)) : 4;
		*array = g_renew (gchar*, *array, (*size) + 1);
	}
	(*array)[(*length)++] = value;
	(*array)[*length] = NULL;
}


static void rygel_external_container_refresh_child_containers_ready (GObject* source_object, GAsyncResult* _res_, gpointer _user_data_) {
	RygelExternalContainerRefreshChildContainersData* _data_;
	_data_ = _user_data_;
	_data_->_source_object_ = source_object;
	_data_->_res_ = _res_;
	rygel_external_container_refresh_child_containers_co (_data_);
}


static gchar* _variant_get8 (GVariant* value) {
	return g_variant_dup_string (value, NULL);
}


static gchar* _variant_get9 (GVariant* value) {
	return g_variant_dup_string (value, NULL);
}


static guint _variant_get10 (GVariant* value) {
	return g_variant_get_uint32 (value);
}


static gboolean _variant_get11 (GVariant* value) {
	return g_variant_get_boolean (value);
}


static gboolean rygel_external_container_refresh_child_containers_co (RygelExternalContainerRefreshChildContainersData* _data_) {
	switch (_data_->_state_) {
		case 0:
		goto _state_0;
		case 1:
		goto _state_1;
		default:
		g_assert_not_reached ();
	}
	_state_0:
	_data_->_tmp0_ = NULL;
	_data_->_tmp0_ = g_new0 (gchar*, 0 + 1);
	_data_->filter_length1 = 0;
	_data_->_filter_size_ = 0;
	_data_->filter = _data_->_tmp0_;
	_data_->filter_length1 = 0;
	_data_->_filter_size_ = _data_->filter_length1;
	{
		_data_->object_prop_collection_length1 = 0;
		_data_->_object_prop_collection_size_ = 0;
		_data_->object_prop_collection = RYGEL_EXTERNAL_MEDIA_OBJECT_PROXY_PROPERTIES;
		_data_->object_prop_collection_length1 = G_N_ELEMENTS (RYGEL_EXTERNAL_MEDIA_OBJECT_PROXY_PROPERTIES);
		for (_data_->object_prop_it = 0; _data_->object_prop_it < G_N_ELEMENTS (RYGEL_EXTERNAL_MEDIA_OBJECT_PROXY_PROPERTIES); _data_->object_prop_it = _data_->object_prop_it + 1) {
			_data_->object_prop = _data_->object_prop_collection[_data_->object_prop_it];
			{
				_data_->_tmp1_ = NULL;
				_data_->_tmp1__length1 = 0;
				_data_->_tmp1_ = _data_->filter;
				_data_->_tmp1__length1 = _data_->filter_length1;
				_data_->_tmp2_ = NULL;
				_data_->_tmp2_ = _data_->object_prop;
				_data_->_tmp3_ = NULL;
				_data_->_tmp3_ = g_strdup (_data_->_tmp2_);
				_vala_array_add7 (&_data_->filter, &_data_->filter_length1, &_data_->_filter_size_, _data_->_tmp3_);
			}
		}
	}
	{
		_data_->container_prop_collection_length1 = 0;
		_data_->_container_prop_collection_size_ = 0;
		_data_->container_prop_collection = RYGEL_EXTERNAL_MEDIA_CONTAINER_PROXY_PROPERTIES;
		_data_->container_prop_collection_length1 = G_N_ELEMENTS (RYGEL_EXTERNAL_MEDIA_CONTAINER_PROXY_PROPERTIES);
		for (_data_->container_prop_it = 0; _data_->container_prop_it < G_N_ELEMENTS (RYGEL_EXTERNAL_MEDIA_CONTAINER_PROXY_PROPERTIES); _data_->container_prop_it = _data_->container_prop_it + 1) {
			_data_->container_prop = _data_->container_prop_collection[_data_->container_prop_it];
			{
				_data_->_tmp4_ = NULL;
				_data_->_tmp4__length1 = 0;
				_data_->_tmp4_ = _data_->filter;
				_data_->_tmp4__length1 = _data_->filter_length1;
				_data_->_tmp5_ = NULL;
				_data_->_tmp5_ = _data_->container_prop;
				_data_->_tmp6_ = NULL;
				_data_->_tmp6_ = g_strdup (_data_->_tmp5_);
				_vala_array_add8 (&_data_->filter, &_data_->filter_length1, &_data_->_filter_size_, _data_->_tmp6_);
			}
		}
	}
	_data_->_tmp7_ = NULL;
	_data_->_tmp7_ = _data_->self->actual_container;
	_data_->_tmp8_ = NULL;
	_data_->_tmp8__length1 = 0;
	_data_->_tmp8_ = _data_->filter;
	_data_->_tmp8__length1 = _data_->filter_length1;
	_data_->_tmp9_ = 0;
	_data_->_state_ = 1;
	rygel_external_media_container_proxy_list_containers (_data_->_tmp7_, (guint) 0, (guint) 0, _data_->_tmp8_, _data_->_tmp8__length1, rygel_external_container_refresh_child_containers_ready, _data_);
	return FALSE;
	_state_1:
	_data_->_tmp10_ = NULL;
	_data_->_tmp10_ = rygel_external_media_container_proxy_list_containers_finish (_data_->_tmp7_, _data_->_res_, &_data_->_tmp9_, &_data_->_inner_error_);
	_data_->children_props_length1 = 0;
	_data_->_children_props_size_ = 0;
	_data_->children_props = _data_->_tmp10_;
	_data_->children_props_length1 = _data_->_tmp9_;
	_data_->_children_props_size_ = _data_->children_props_length1;
	if (G_UNLIKELY (_data_->_inner_error_ != NULL)) {
		g_simple_async_result_set_from_error (_data_->_async_result, _data_->_inner_error_);
		g_error_free (_data_->_inner_error_);
		_data_->filter = (_vala_array_free (_data_->filter, _data_->filter_length1, (GDestroyNotify) g_free), NULL);
		if (_data_->_state_ == 0) {
			g_simple_async_result_complete_in_idle (_data_->_async_result);
		} else {
			g_simple_async_result_complete (_data_->_async_result);
		}
		g_object_unref (_data_->_async_result);
		return FALSE;
	}
	_data_->_tmp11_ = NULL;
	_data_->_tmp11_ = _data_->self->priv->containers;
	gee_abstract_collection_clear ((GeeAbstractCollection*) _data_->_tmp11_);
	_data_->_tmp12_ = NULL;
	_data_->_tmp12__length1 = 0;
	_data_->_tmp12_ = _data_->children_props;
	_data_->_tmp12__length1 = _data_->children_props_length1;
	{
		_data_->props_collection_length1 = 0;
		_data_->_props_collection_size_ = 0;
		_data_->props_collection = _data_->_tmp12_;
		_data_->props_collection_length1 = _data_->_tmp12__length1;
		for (_data_->props_it = 0; _data_->props_it < _data_->_tmp12__length1; _data_->props_it = _data_->props_it + 1) {
			_data_->_tmp13_ = NULL;
			_data_->_tmp13_ = _g_hash_table_ref0 (_data_->props_collection[_data_->props_it]);
			_data_->props = _data_->_tmp13_;
			{
				_data_->_tmp14_ = NULL;
				_data_->_tmp14_ = _data_->props;
				_data_->_tmp15_ = NULL;
				_data_->_tmp15_ = g_hash_table_lookup (_data_->_tmp14_, "Path");
				_data_->_tmp16_ = NULL;
				_data_->_tmp16_ = _variant_get8 ((GVariant*) _data_->_tmp15_);
				_data_->path = _data_->_tmp16_;
				_data_->_tmp17_ = NULL;
				_data_->_tmp17_ = _data_->props;
				_data_->_tmp18_ = NULL;
				_data_->_tmp18_ = g_hash_table_lookup (_data_->_tmp17_, "DisplayName");
				_data_->_tmp19_ = NULL;
				_data_->_tmp19_ = _variant_get9 ((GVariant*) _data_->_tmp18_);
				_data_->title = _data_->_tmp19_;
				_data_->_tmp20_ = NULL;
				_data_->_tmp20_ = _data_->props;
				_data_->_tmp21_ = NULL;
				_data_->_tmp21_ = g_hash_table_lookup (_data_->_tmp20_, "ChildCount");
				_data_->_tmp22_ = 0U;
				_data_->_tmp22_ = _variant_get10 ((GVariant*) _data_->_tmp21_);
				_data_->child_count = _data_->_tmp22_;
				_data_->_tmp23_ = NULL;
				_data_->_tmp23_ = _data_->props;
				_data_->_tmp24_ = NULL;
				_data_->_tmp24_ = g_hash_table_lookup (_data_->_tmp23_, "Searchable");
				_data_->_tmp25_ = FALSE;
				_data_->_tmp25_ = _variant_get11 ((GVariant*) _data_->_tmp24_);
				_data_->searchable = _data_->_tmp25_;
				_data_->_tmp26_ = NULL;
				_data_->_tmp26_ = _data_->path;
				_data_->_tmp27_ = NULL;
				_data_->_tmp27_ = _data_->title;
				_data_->_tmp28_ = 0U;
				_data_->_tmp28_ = _data_->child_count;
				_data_->_tmp29_ = FALSE;
				_data_->_tmp29_ = _data_->searchable;
				_data_->_tmp30_ = NULL;
				_data_->_tmp30_ = _data_->self->service_name;
				_data_->_tmp31_ = NULL;
				_data_->_tmp31_ = _data_->path;
				_data_->_tmp32_ = NULL;
				_data_->_tmp32_ = rygel_external_container_new (_data_->_tmp26_, _data_->_tmp27_, _data_->_tmp28_, _data_->_tmp29_, _data_->_tmp30_, _data_->_tmp31_, _data_->self, &_data_->_inner_error_);
				_data_->container = _data_->_tmp32_;
				if (G_UNLIKELY (_data_->_inner_error_ != NULL)) {
					g_simple_async_result_set_from_error (_data_->_async_result, _data_->_inner_error_);
					g_error_free (_data_->_inner_error_);
					_g_free0 (_data_->title);
					_g_free0 (_data_->path);
					_g_hash_table_unref0 (_data_->props);
					_data_->children_props = (_vala_array_free (_data_->children_props, _data_->children_props_length1, (GDestroyNotify) g_hash_table_unref), NULL);
					_data_->filter = (_vala_array_free (_data_->filter, _data_->filter_length1, (GDestroyNotify) g_free), NULL);
					if (_data_->_state_ == 0) {
						g_simple_async_result_complete_in_idle (_data_->_async_result);
					} else {
						g_simple_async_result_complete (_data_->_async_result);
					}
					g_object_unref (_data_->_async_result);
					return FALSE;
				}
				_data_->_tmp33_ = NULL;
				_data_->_tmp33_ = _data_->self->priv->containers;
				_data_->_tmp34_ = NULL;
				_data_->_tmp34_ = _data_->container;
				gee_abstract_collection_add ((GeeAbstractCollection*) _data_->_tmp33_, _data_->_tmp34_);
				_g_object_unref0 (_data_->container);
				_g_free0 (_data_->title);
				_g_free0 (_data_->path);
				_g_hash_table_unref0 (_data_->props);
			}
		}
	}
	_data_->children_props = (_vala_array_free (_data_->children_props, _data_->children_props_length1, (GDestroyNotify) g_hash_table_unref), NULL);
	_data_->filter = (_vala_array_free (_data_->filter, _data_->filter_length1, (GDestroyNotify) g_free), NULL);
	if (_data_->_state_ == 0) {
		g_simple_async_result_complete_in_idle (_data_->_async_result);
	} else {
		g_simple_async_result_complete (_data_->_async_result);
	}
	g_object_unref (_data_->_async_result);
	return FALSE;
}


static void rygel_external_container_update_container_data_free (gpointer _data) {
	RygelExternalContainerUpdateContainerData* _data_;
	_data_ = _data;
	_g_object_unref0 (_data_->self);
	g_slice_free (RygelExternalContainerUpdateContainerData, _data_);
}


static void rygel_external_container_update_container (RygelExternalContainer* self, gboolean connect_signal, GAsyncReadyCallback _callback_, gpointer _user_data_) {
	RygelExternalContainerUpdateContainerData* _data_;
	RygelExternalContainer* _tmp0_ = NULL;
	gboolean _tmp1_ = FALSE;
	_data_ = g_slice_new0 (RygelExternalContainerUpdateContainerData);
	_data_->_async_result = g_simple_async_result_new (G_OBJECT (self), _callback_, _user_data_, rygel_external_container_update_container);
	g_simple_async_result_set_op_res_gpointer (_data_->_async_result, _data_, rygel_external_container_update_container_data_free);
	_tmp0_ = _g_object_ref0 (self);
	_data_->self = _tmp0_;
	_tmp1_ = connect_signal;
	_data_->connect_signal = _tmp1_;
	rygel_external_container_update_container_co (_data_);
}


static void rygel_external_container_update_container_finish (RygelExternalContainer* self, GAsyncResult* _res_) {
	RygelExternalContainerUpdateContainerData* _data_;
	_data_ = g_simple_async_result_get_op_res_gpointer (G_SIMPLE_ASYNC_RESULT (_res_));
}


static void rygel_external_container_update_container_ready (GObject* source_object, GAsyncResult* _res_, gpointer _user_data_) {
	RygelExternalContainerUpdateContainerData* _data_;
	_data_ = _user_data_;
	_data_->_source_object_ = source_object;
	_data_->_res_ = _res_;
	rygel_external_container_update_container_co (_data_);
}


static guint _variant_get12 (GVariant* value) {
	return g_variant_get_uint32 (value);
}


static void _rygel_external_container_on_updated_rygel_external_media_container_proxy_updated (RygelExternalMediaContainerProxy* _sender, gpointer self) {
	rygel_external_container_on_updated ((RygelExternalContainer*) self, _sender);
}


static gboolean rygel_external_container_update_container_co (RygelExternalContainerUpdateContainerData* _data_) {
	switch (_data_->_state_) {
		case 0:
		goto _state_0;
		case 1:
		goto _state_1;
		case 2:
		goto _state_2;
		case 3:
		goto _state_3;
		case 4:
		goto _state_4;
		default:
		g_assert_not_reached ();
	}
	_state_0:
	{
		_data_->_tmp0_ = NULL;
		_data_->_tmp0_ = _data_->self->service_name;
		_data_->_tmp1_ = NULL;
		_data_->_tmp1_ = _data_->self->actual_container;
		_data_->_tmp2_ = NULL;
		_data_->_tmp2_ = g_dbus_proxy_get_object_path ((GDBusProxy*) _data_->_tmp1_);
		_data_->_state_ = 1;
		g_async_initable_new_async (RYGEL_EXTERNAL_FREE_DESKTOP_TYPE_PROPERTIES_PROXY, 0, NULL, rygel_external_container_update_container_ready, _data_, "g-flags", G_DBUS_PROXY_FLAGS_DO_NOT_LOAD_PROPERTIES, "g-name", _data_->_tmp0_, "g-bus-type", G_BUS_TYPE_SESSION, "g-object-path", _data_->_tmp2_, "g-interface-name", "org.freedesktop.DBus.Properties", "g-interface-info", g_type_get_qdata (RYGEL_EXTERNAL_FREE_DESKTOP_TYPE_PROPERTIES, g_quark_from_static_string ("vala-dbus-interface-info")), NULL);
		return FALSE;
		_state_1:
		_data_->_tmp3_ = NULL;
		_data_->_tmp3_ = g_async_initable_new_finish (_data_->_source_object_, _data_->_res_, &_data_->_inner_error_);
		_data_->props_iface = (RygelExternalFreeDesktopProperties*) _data_->_tmp3_;
		if (G_UNLIKELY (_data_->_inner_error_ != NULL)) {
			goto __catch0_g_error;
		}
		_data_->_tmp4_ = NULL;
		_data_->_tmp4_ = _data_->props_iface;
		_data_->_state_ = 2;
		rygel_external_free_desktop_properties_get_all (_data_->_tmp4_, RYGEL_EXTERNAL_MEDIA_CONTAINER_PROXY_IFACE, rygel_external_container_update_container_ready, _data_);
		return FALSE;
		_state_2:
		_data_->_tmp5_ = NULL;
		_data_->_tmp5_ = rygel_external_free_desktop_properties_get_all_finish (_data_->_tmp4_, _data_->_res_, &_data_->_inner_error_);
		_data_->props = _data_->_tmp5_;
		if (G_UNLIKELY (_data_->_inner_error_ != NULL)) {
			_g_object_unref0 (_data_->props_iface);
			goto __catch0_g_error;
		}
		_data_->_tmp6_ = NULL;
		_data_->_tmp6_ = _data_->props;
		_data_->_tmp7_ = NULL;
		_data_->_tmp7_ = g_hash_table_lookup (_data_->_tmp6_, "ChildCount");
		_data_->_tmp8_ = 0U;
		_data_->_tmp8_ = _variant_get12 ((GVariant*) _data_->_tmp7_);
		_data_->child_count = _data_->_tmp8_;
		_data_->_tmp9_ = 0U;
		_data_->_tmp9_ = _data_->child_count;
		if (_data_->_tmp9_ < ((guint) G_MAXINT)) {
			_data_->_tmp10_ = 0U;
			_data_->_tmp10_ = _data_->child_count;
			rygel_media_container_set_child_count ((RygelMediaContainer*) _data_->self, (gint) _data_->_tmp10_);
		}
		_data_->_tmp12_ = NULL;
		_data_->_tmp12_ = _data_->props_iface;
		_data_->_state_ = 3;
		rygel_external_free_desktop_properties_get_all (_data_->_tmp12_, RYGEL_EXTERNAL_MEDIA_OBJECT_PROXY_IFACE, rygel_external_container_update_container_ready, _data_);
		return FALSE;
		_state_3:
		_data_->_tmp13_ = NULL;
		_data_->_tmp13_ = rygel_external_free_desktop_properties_get_all_finish (_data_->_tmp12_, _data_->_res_, &_data_->_inner_error_);
		_data_->_tmp11_ = _data_->_tmp13_;
		if (G_UNLIKELY (_data_->_inner_error_ != NULL)) {
			_g_hash_table_unref0 (_data_->props);
			_g_object_unref0 (_data_->props_iface);
			goto __catch0_g_error;
		}
		_data_->_tmp14_ = NULL;
		_data_->_tmp14_ = _data_->_tmp11_;
		_data_->_tmp11_ = NULL;
		_g_hash_table_unref0 (_data_->props);
		_data_->props = _data_->_tmp14_;
		_data_->_tmp15_ = NULL;
		_data_->_tmp15_ = _data_->props;
		_data_->_tmp16_ = NULL;
		_data_->_tmp16_ = rygel_media_object_get_id ((RygelMediaObject*) _data_->self);
		_data_->_tmp17_ = NULL;
		_data_->_tmp17_ = _data_->_tmp16_;
		_data_->_tmp18_ = NULL;
		_data_->_tmp18_ = _data_->self->service_name;
		_data_->_tmp19_ = NULL;
		_data_->_tmp19_ = rygel_external_get_mandatory_string_value (_data_->_tmp15_, "DisplayName", _data_->_tmp17_, _data_->_tmp18_);
		_data_->_tmp20_ = NULL;
		_data_->_tmp20_ = _data_->_tmp19_;
		rygel_media_object_set_title ((RygelMediaObject*) _data_->self, _data_->_tmp20_);
		_g_free0 (_data_->_tmp20_);
		_g_hash_table_unref0 (_data_->_tmp11_);
		_g_hash_table_unref0 (_data_->props);
		_g_object_unref0 (_data_->props_iface);
	}
	goto __finally0;
	__catch0_g_error:
	{
		_data_->property_error = _data_->_inner_error_;
		_data_->_inner_error_ = NULL;
		_data_->_tmp21_ = NULL;
		_data_->_tmp21_ = _data_->self->actual_container;
		_data_->_tmp22_ = NULL;
		_data_->_tmp22_ = g_dbus_proxy_get_object_path ((GDBusProxy*) _data_->_tmp21_);
		_data_->_tmp23_ = NULL;
		_data_->_tmp23_ = _data_->property_error;
		_data_->_tmp24_ = NULL;
		_data_->_tmp24_ = _data_->_tmp23_->message;
		g_warning ("rygel-external-container.vala:349: Failed to update information about " \
"container '%s': %s", _data_->_tmp22_, _data_->_tmp24_);
		_g_error_free0 (_data_->property_error);
	}
	__finally0:
	if (G_UNLIKELY (_data_->_inner_error_ != NULL)) {
		g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _data_->_inner_error_->message, g_quark_to_string (_data_->_inner_error_->domain), _data_->_inner_error_->code);
		g_clear_error (&_data_->_inner_error_);
		return FALSE;
	}
	{
		_data_->_tmp25_ = 0;
		_data_->_tmp25_ = rygel_media_container_get_child_count ((RygelMediaContainer*) _data_->self);
		_data_->_tmp26_ = 0;
		_data_->_tmp26_ = _data_->_tmp25_;
		if (_data_->_tmp26_ < G_MAXINT) {
			_data_->_state_ = 4;
			rygel_external_container_refresh_child_containers (_data_->self, rygel_external_container_update_container_ready, _data_);
			return FALSE;
			_state_4:
			rygel_external_container_refresh_child_containers_finish (_data_->self, _data_->_res_, &_data_->_inner_error_);
			if (G_UNLIKELY (_data_->_inner_error_ != NULL)) {
				goto __catch1_g_error;
			}
		}
	}
	goto __finally1;
	__catch1_g_error:
	{
		_data_->err = _data_->_inner_error_;
		_data_->_inner_error_ = NULL;
		_data_->_tmp27_ = NULL;
		_data_->_tmp27_ = _data_->self->actual_container;
		_data_->_tmp28_ = NULL;
		_data_->_tmp28_ = g_dbus_proxy_get_object_path ((GDBusProxy*) _data_->_tmp27_);
		_data_->_tmp29_ = NULL;
		_data_->_tmp29_ = _data_->err;
		_data_->_tmp30_ = NULL;
		_data_->_tmp30_ = _data_->_tmp29_->message;
		g_warning ("rygel-external-container.vala:360: Failed to update information about " \
"container '%s': %s", _data_->_tmp28_, _data_->_tmp30_);
		_g_error_free0 (_data_->err);
	}
	__finally1:
	if (G_UNLIKELY (_data_->_inner_error_ != NULL)) {
		g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _data_->_inner_error_->message, g_quark_to_string (_data_->_inner_error_->domain), _data_->_inner_error_->code);
		g_clear_error (&_data_->_inner_error_);
		return FALSE;
	}
	rygel_media_container_updated ((RygelMediaContainer*) _data_->self, NULL, RYGEL_OBJECT_EVENT_TYPE_MODIFIED, FALSE);
	_data_->_tmp31_ = FALSE;
	_data_->_tmp31_ = _data_->connect_signal;
	if (_data_->_tmp31_) {
		_data_->_tmp32_ = NULL;
		_data_->_tmp32_ = _data_->self->actual_container;
		g_signal_connect_object (_data_->_tmp32_, "updated", (GCallback) _rygel_external_container_on_updated_rygel_external_media_container_proxy_updated, _data_->self, 0);
	}
	if (_data_->_state_ == 0) {
		g_simple_async_result_complete_in_idle (_data_->_async_result);
	} else {
		g_simple_async_result_complete (_data_->_async_result);
	}
	g_object_unref (_data_->_async_result);
	return FALSE;
}


static void rygel_external_container_on_updated (RygelExternalContainer* self, RygelExternalMediaContainerProxy* actual_container) {
	g_return_if_fail (self != NULL);
	g_return_if_fail (actual_container != NULL);
	rygel_external_container_update_container (self, FALSE, NULL, NULL);
}


static RygelMediaContainer* rygel_external_container_find_container_by_id (RygelExternalContainer* self, const gchar* id) {
	RygelMediaContainer* result = NULL;
	RygelMediaContainer* target = NULL;
	g_return_val_if_fail (self != NULL, NULL);
	g_return_val_if_fail (id != NULL, NULL);
	target = NULL;
	{
		GeeArrayList* _container_list = NULL;
		GeeArrayList* _tmp0_ = NULL;
		GeeArrayList* _tmp1_ = NULL;
		gint _container_size = 0;
		GeeArrayList* _tmp2_ = NULL;
		gint _tmp3_ = 0;
		gint _tmp4_ = 0;
		gint _container_index = 0;
		_tmp0_ = self->priv->containers;
		_tmp1_ = _g_object_ref0 (_tmp0_);
		_container_list = _tmp1_;
		_tmp2_ = _container_list;
		_tmp3_ = gee_abstract_collection_get_size ((GeeCollection*) _tmp2_);
		_tmp4_ = _tmp3_;
		_container_size = _tmp4_;
		_container_index = -1;
		while (TRUE) {
			gint _tmp5_ = 0;
			gint _tmp6_ = 0;
			gint _tmp7_ = 0;
			RygelExternalContainer* container = NULL;
			GeeArrayList* _tmp8_ = NULL;
			gint _tmp9_ = 0;
			gpointer _tmp10_ = NULL;
			RygelExternalContainer* _tmp11_ = NULL;
			const gchar* _tmp12_ = NULL;
			const gchar* _tmp13_ = NULL;
			const gchar* _tmp14_ = NULL;
			_tmp5_ = _container_index;
			_container_index = _tmp5_ + 1;
			_tmp6_ = _container_index;
			_tmp7_ = _container_size;
			if (!(_tmp6_ < _tmp7_)) {
				break;
			}
			_tmp8_ = _container_list;
			_tmp9_ = _container_index;
			_tmp10_ = gee_abstract_list_get ((GeeAbstractList*) _tmp8_, _tmp9_);
			container = (RygelExternalContainer*) _tmp10_;
			_tmp11_ = container;
			_tmp12_ = rygel_media_object_get_id ((RygelMediaObject*) _tmp11_);
			_tmp13_ = _tmp12_;
			_tmp14_ = id;
			if (g_strcmp0 (_tmp13_, _tmp14_) == 0) {
				RygelExternalContainer* _tmp15_ = NULL;
				RygelMediaContainer* _tmp16_ = NULL;
				_tmp15_ = container;
				_tmp16_ = _g_object_ref0 ((RygelMediaContainer*) _tmp15_);
				_g_object_unref0 (target);
				target = _tmp16_;
				_g_object_unref0 (container);
				break;
			}
			_g_object_unref0 (container);
		}
		_g_object_unref0 (_container_list);
	}
	result = target;
	return result;
}


static RygelSearchExpression* rygel_external_container_translate_expression (RygelExternalContainer* self, RygelSearchExpression* upnp_expression) {
	RygelSearchExpression* result = NULL;
	RygelSearchExpression* _tmp0_ = NULL;
	g_return_val_if_fail (self != NULL, NULL);
	g_return_val_if_fail (upnp_expression != NULL, NULL);
	_tmp0_ = upnp_expression;
	if (G_TYPE_CHECK_INSTANCE_TYPE (_tmp0_, RYGEL_TYPE_RELATIONAL_EXPRESSION)) {
		RygelRelationalExpression* expression = NULL;
		RygelSearchExpression* _tmp1_ = NULL;
		RygelRelationalExpression* _tmp2_ = NULL;
		RygelRelationalExpression* ext_expression = NULL;
		RygelRelationalExpression* _tmp3_ = NULL;
		RygelRelationalExpression* _tmp4_ = NULL;
		RygelRelationalExpression* _tmp5_ = NULL;
		gconstpointer _tmp6_ = NULL;
		RygelRelationalExpression* _tmp7_ = NULL;
		RygelRelationalExpression* _tmp8_ = NULL;
		gconstpointer _tmp9_ = NULL;
		gchar* _tmp10_ = NULL;
		RygelRelationalExpression* _tmp11_ = NULL;
		RygelRelationalExpression* _tmp12_ = NULL;
		gconstpointer _tmp13_ = NULL;
		gchar* _tmp14_ = NULL;
		_tmp1_ = upnp_expression;
		_tmp2_ = _rygel_search_expression_ref0 (G_TYPE_CHECK_INSTANCE_TYPE (_tmp1_, RYGEL_TYPE_RELATIONAL_EXPRESSION) ? ((RygelRelationalExpression*) _tmp1_) : NULL);
		expression = _tmp2_;
		_tmp3_ = rygel_relational_expression_new ();
		ext_expression = _tmp3_;
		_tmp4_ = ext_expression;
		_tmp5_ = expression;
		_tmp6_ = ((RygelSearchExpression*) _tmp5_)->op;
		((RygelSearchExpression*) _tmp4_)->op = (gpointer) ((gintptr) ((GUPnPSearchCriteriaOp) ((gintptr) _tmp6_)));
		_tmp7_ = ext_expression;
		_tmp8_ = expression;
		_tmp9_ = ((RygelSearchExpression*) _tmp8_)->operand1;
		_tmp10_ = rygel_external_container_translate_property (self, (const gchar*) _tmp9_);
		_g_free0 (((RygelSearchExpression*) _tmp7_)->operand1);
		((RygelSearchExpression*) _tmp7_)->operand1 = _tmp10_;
		_tmp11_ = ext_expression;
		_tmp12_ = expression;
		_tmp13_ = ((RygelSearchExpression*) _tmp12_)->operand2;
		_tmp14_ = g_strdup ((const gchar*) _tmp13_);
		_g_free0 (((RygelSearchExpression*) _tmp11_)->operand2);
		((RygelSearchExpression*) _tmp11_)->operand2 = _tmp14_;
		result = (RygelSearchExpression*) ext_expression;
		_rygel_search_expression_unref0 (expression);
		return result;
	} else {
		RygelLogicalExpression* expression = NULL;
		RygelSearchExpression* _tmp15_ = NULL;
		RygelLogicalExpression* _tmp16_ = NULL;
		RygelLogicalExpression* ext_expression = NULL;
		RygelLogicalExpression* _tmp17_ = NULL;
		RygelLogicalExpression* _tmp18_ = NULL;
		RygelLogicalExpression* _tmp19_ = NULL;
		gconstpointer _tmp20_ = NULL;
		RygelLogicalExpression* _tmp21_ = NULL;
		RygelLogicalExpression* _tmp22_ = NULL;
		gconstpointer _tmp23_ = NULL;
		RygelSearchExpression* _tmp24_ = NULL;
		RygelLogicalExpression* _tmp25_ = NULL;
		RygelLogicalExpression* _tmp26_ = NULL;
		gconstpointer _tmp27_ = NULL;
		RygelSearchExpression* _tmp28_ = NULL;
		_tmp15_ = upnp_expression;
		_tmp16_ = _rygel_search_expression_ref0 (G_TYPE_CHECK_INSTANCE_TYPE (_tmp15_, RYGEL_TYPE_LOGICAL_EXPRESSION) ? ((RygelLogicalExpression*) _tmp15_) : NULL);
		expression = _tmp16_;
		_tmp17_ = rygel_logical_expression_new ();
		ext_expression = _tmp17_;
		_tmp18_ = ext_expression;
		_tmp19_ = expression;
		_tmp20_ = ((RygelSearchExpression*) _tmp19_)->op;
		((RygelSearchExpression*) _tmp18_)->op = (gpointer) ((gintptr) ((RygelLogicalOperator) ((gintptr) _tmp20_)));
		_tmp21_ = ext_expression;
		_tmp22_ = expression;
		_tmp23_ = ((RygelSearchExpression*) _tmp22_)->operand1;
		_tmp24_ = rygel_external_container_translate_expression (self, (RygelSearchExpression*) _tmp23_);
		_rygel_search_expression_unref0 (((RygelSearchExpression*) _tmp21_)->operand1);
		((RygelSearchExpression*) _tmp21_)->operand1 = _tmp24_;
		_tmp25_ = ext_expression;
		_tmp26_ = expression;
		_tmp27_ = ((RygelSearchExpression*) _tmp26_)->operand2;
		_tmp28_ = rygel_external_container_translate_expression (self, (RygelSearchExpression*) _tmp27_);
		_rygel_search_expression_unref0 (((RygelSearchExpression*) _tmp25_)->operand2);
		((RygelSearchExpression*) _tmp25_)->operand2 = _tmp28_;
		result = (RygelSearchExpression*) ext_expression;
		_rygel_search_expression_unref0 (expression);
		return result;
	}
}


gchar* rygel_external_container_translate_property (RygelExternalContainer* self, const gchar* property) {
	gchar* result = NULL;
	const gchar* _tmp0_ = NULL;
	const gchar* _tmp1_ = NULL;
	GQuark _tmp3_ = 0U;
	static GQuark _tmp2_label0 = 0;
	static GQuark _tmp2_label1 = 0;
	static GQuark _tmp2_label2 = 0;
	static GQuark _tmp2_label3 = 0;
	static GQuark _tmp2_label4 = 0;
	static GQuark _tmp2_label5 = 0;
	static GQuark _tmp2_label6 = 0;
	g_return_val_if_fail (self != NULL, NULL);
	g_return_val_if_fail (property != NULL, NULL);
	_tmp0_ = property;
	_tmp1_ = _tmp0_;
	_tmp3_ = (NULL == _tmp1_) ? 0 : g_quark_from_string (_tmp1_);
	if (_tmp3_ == ((0 != _tmp2_label0) ? _tmp2_label0 : (_tmp2_label0 = g_quark_from_static_string ("@id")))) {
		switch (0) {
			default:
			{
				gchar* _tmp4_ = NULL;
				_tmp4_ = g_strdup ("Path");
				result = _tmp4_;
				return result;
			}
		}
	} else if (_tmp3_ == ((0 != _tmp2_label1) ? _tmp2_label1 : (_tmp2_label1 = g_quark_from_static_string ("@parentID")))) {
		switch (0) {
			default:
			{
				gchar* _tmp5_ = NULL;
				_tmp5_ = g_strdup ("Parent");
				result = _tmp5_;
				return result;
			}
		}
	} else if (_tmp3_ == ((0 != _tmp2_label2) ? _tmp2_label2 : (_tmp2_label2 = g_quark_from_static_string ("dc:title")))) {
		switch (0) {
			default:
			{
				gchar* _tmp6_ = NULL;
				_tmp6_ = g_strdup ("DisplayName");
				result = _tmp6_;
				return result;
			}
		}
	} else if (((_tmp3_ == ((0 != _tmp2_label3) ? _tmp2_label3 : (_tmp2_label3 = g_quark_from_static_string ("dc:creator")))) || (_tmp3_ == ((0 != _tmp2_label4) ? _tmp2_label4 : (_tmp2_label4 = g_quark_from_static_string ("upnp:artist"))))) || (_tmp3_ == ((0 != _tmp2_label5) ? _tmp2_label5 : (_tmp2_label5 = g_quark_from_static_string ("upnp:author"))))) {
		switch (0) {
			default:
			{
				gchar* _tmp7_ = NULL;
				_tmp7_ = g_strdup ("Artist");
				result = _tmp7_;
				return result;
			}
		}
	} else if (_tmp3_ == ((0 != _tmp2_label6) ? _tmp2_label6 : (_tmp2_label6 = g_quark_from_static_string ("upnp:album")))) {
		switch (0) {
			default:
			{
				gchar* _tmp8_ = NULL;
				_tmp8_ = g_strdup ("Album");
				result = _tmp8_;
				return result;
			}
		}
	} else {
		switch (0) {
			default:
			{
				const gchar* _tmp9_ = NULL;
				gchar* _tmp10_ = NULL;
				_tmp9_ = property;
				_tmp10_ = g_strdup (_tmp9_);
				result = _tmp10_;
				return result;
			}
		}
	}
}


static GeeArrayList* rygel_external_container_real_get_search_classes (RygelSearchableContainer* base) {
	GeeArrayList* result;
	RygelExternalContainer* self;
	GeeArrayList* _tmp0_ = NULL;
	self = (RygelExternalContainer*) base;
	_tmp0_ = self->priv->_search_classes;
	result = _tmp0_;
	return result;
}


static void rygel_external_container_real_set_search_classes (RygelSearchableContainer* base, GeeArrayList* value) {
	RygelExternalContainer* self;
	GeeArrayList* _tmp0_ = NULL;
	GeeArrayList* _tmp1_ = NULL;
	self = (RygelExternalContainer*) base;
	_tmp0_ = value;
	_tmp1_ = _g_object_ref0 (_tmp0_);
	_g_object_unref0 (self->priv->_search_classes);
	self->priv->_search_classes = _tmp1_;
	g_object_notify ((GObject *) self, "search-classes");
}


static void rygel_external_container_class_init (RygelExternalContainerClass * klass) {
	rygel_external_container_parent_class = g_type_class_peek_parent (klass);
	g_type_class_add_private (klass, sizeof (RygelExternalContainerPrivate));
	((RygelMediaContainerClass *) klass)->get_children = rygel_external_container_real_get_children;
	((RygelMediaContainerClass *) klass)->get_children_finish = rygel_external_container_real_get_children_finish;
	((RygelMediaContainerClass *) klass)->find_object = rygel_external_container_real_find_object;
	((RygelMediaContainerClass *) klass)->find_object_finish = rygel_external_container_real_find_object_finish;
	G_OBJECT_CLASS (klass)->get_property = _vala_rygel_external_container_get_property;
	G_OBJECT_CLASS (klass)->set_property = _vala_rygel_external_container_set_property;
	G_OBJECT_CLASS (klass)->finalize = rygel_external_container_finalize;
	g_object_class_install_property (G_OBJECT_CLASS (klass), RYGEL_EXTERNAL_CONTAINER_SEARCH_CLASSES, g_param_spec_object ("search-classes", "search-classes", "search-classes", GEE_TYPE_ARRAY_LIST, G_PARAM_STATIC_NAME | G_PARAM_STATIC_NICK | G_PARAM_STATIC_BLURB | G_PARAM_READABLE | G_PARAM_WRITABLE));
}


static void rygel_external_container_rygel_searchable_container_interface_init (RygelSearchableContainerIface * iface) {
	rygel_external_container_rygel_searchable_container_parent_iface = g_type_interface_peek_parent (iface);
	iface->search = (RygelMediaObjects* (*)(RygelSearchableContainer*, RygelSearchExpression*, guint, guint, guint*, const gchar*, GCancellable*, GError**)) rygel_external_container_real_search;
	iface->search_finish = rygel_external_container_real_search_finish;
	iface->get_search_classes = rygel_external_container_real_get_search_classes;
	iface->set_search_classes = rygel_external_container_real_set_search_classes;
}


static void rygel_external_container_instance_init (RygelExternalContainer * self) {
	self->priv = RYGEL_EXTERNAL_CONTAINER_GET_PRIVATE (self);
}


static void rygel_external_container_finalize (GObject* obj) {
	RygelExternalContainer * self;
	RygelMediaContainer* _tmp0_ = NULL;
	RygelMediaContainer* _tmp1_ = NULL;
	self = G_TYPE_CHECK_INSTANCE_CAST (obj, RYGEL_EXTERNAL_TYPE_CONTAINER, RygelExternalContainer);
	_tmp0_ = rygel_media_object_get_parent ((RygelMediaObject*) self);
	_tmp1_ = _tmp0_;
	if (_tmp1_ != NULL) {
		RygelMediaContainer* _tmp2_ = NULL;
		RygelMediaContainer* _tmp3_ = NULL;
		_tmp2_ = rygel_media_object_get_parent ((RygelMediaObject*) self);
		_tmp3_ = _tmp2_;
		g_object_remove_weak_pointer ((GObject*) _tmp3_, &((RygelMediaObject*) self)->parent_ptr);
	}
	_g_object_unref0 (self->actual_container);
	_g_free0 (self->service_name);
	_rygel_external_item_factory_unref0 (self->priv->item_factory);
	_g_object_unref0 (self->priv->containers);
	_g_object_unref0 (self->priv->_search_classes);
	G_OBJECT_CLASS (rygel_external_container_parent_class)->finalize (obj);
}


/**
 * Represents an external container.
 */
GType rygel_external_container_get_type (void) {
	static volatile gsize rygel_external_container_type_id__volatile = 0;
	if (g_once_init_enter (&rygel_external_container_type_id__volatile)) {
		static const GTypeInfo g_define_type_info = { sizeof (RygelExternalContainerClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) rygel_external_container_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (RygelExternalContainer), 0, (GInstanceInitFunc) rygel_external_container_instance_init, NULL };
		static const GInterfaceInfo rygel_searchable_container_info = { (GInterfaceInitFunc) rygel_external_container_rygel_searchable_container_interface_init, (GInterfaceFinalizeFunc) NULL, NULL};
		GType rygel_external_container_type_id;
		rygel_external_container_type_id = g_type_register_static (RYGEL_TYPE_MEDIA_CONTAINER, "RygelExternalContainer", &g_define_type_info, 0);
		g_type_add_interface_static (rygel_external_container_type_id, RYGEL_TYPE_SEARCHABLE_CONTAINER, &rygel_searchable_container_info);
		g_once_init_leave (&rygel_external_container_type_id__volatile, rygel_external_container_type_id);
	}
	return rygel_external_container_type_id__volatile;
}


static void _vala_rygel_external_container_get_property (GObject * object, guint property_id, GValue * value, GParamSpec * pspec) {
	RygelExternalContainer * self;
	self = G_TYPE_CHECK_INSTANCE_CAST (object, RYGEL_EXTERNAL_TYPE_CONTAINER, RygelExternalContainer);
	switch (property_id) {
		case RYGEL_EXTERNAL_CONTAINER_SEARCH_CLASSES:
		g_value_set_object (value, rygel_searchable_container_get_search_classes ((RygelSearchableContainer*) self));
		break;
		default:
		G_OBJECT_WARN_INVALID_PROPERTY_ID (object, property_id, pspec);
		break;
	}
}


static void _vala_rygel_external_container_set_property (GObject * object, guint property_id, const GValue * value, GParamSpec * pspec) {
	RygelExternalContainer * self;
	self = G_TYPE_CHECK_INSTANCE_CAST (object, RYGEL_EXTERNAL_TYPE_CONTAINER, RygelExternalContainer);
	switch (property_id) {
		case RYGEL_EXTERNAL_CONTAINER_SEARCH_CLASSES:
		rygel_searchable_container_set_search_classes ((RygelSearchableContainer*) self, g_value_get_object (value));
		break;
		default:
		G_OBJECT_WARN_INVALID_PROPERTY_ID (object, property_id, pspec);
		break;
	}
}


static void _vala_array_destroy (gpointer array, gint array_length, GDestroyNotify destroy_func) {
	if ((array != NULL) && (destroy_func != NULL)) {
		int i;
		for (i = 0; i < array_length; i = i + 1) {
			if (((gpointer*) array)[i] != NULL) {
				destroy_func (((gpointer*) array)[i]);
			}
		}
	}
}


static void _vala_array_free (gpointer array, gint array_length, GDestroyNotify destroy_func) {
	_vala_array_destroy (array, array_length, destroy_func);
	g_free (array);
}



