/* rygel-tracker-query-triplets.c generated by valac 0.25.1.16-16e7a, the Vala compiler
 * generated from rygel-tracker-query-triplets.vala, do not modify */

/*
 * Copyright (C) 2008 Nokia Corporation.
 *
 * Author: Zeeshan Ali <zeenix@gmail.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 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 program; 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 <gee.h>
#include <stdlib.h>
#include <string.h>


#define RYGEL_TRACKER_TYPE_QUERY_TRIPLETS (rygel_tracker_query_triplets_get_type ())
#define RYGEL_TRACKER_QUERY_TRIPLETS(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), RYGEL_TRACKER_TYPE_QUERY_TRIPLETS, RygelTrackerQueryTriplets))
#define RYGEL_TRACKER_QUERY_TRIPLETS_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), RYGEL_TRACKER_TYPE_QUERY_TRIPLETS, RygelTrackerQueryTripletsClass))
#define RYGEL_TRACKER_IS_QUERY_TRIPLETS(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), RYGEL_TRACKER_TYPE_QUERY_TRIPLETS))
#define RYGEL_TRACKER_IS_QUERY_TRIPLETS_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), RYGEL_TRACKER_TYPE_QUERY_TRIPLETS))
#define RYGEL_TRACKER_QUERY_TRIPLETS_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), RYGEL_TRACKER_TYPE_QUERY_TRIPLETS, RygelTrackerQueryTripletsClass))

typedef struct _RygelTrackerQueryTriplets RygelTrackerQueryTriplets;
typedef struct _RygelTrackerQueryTripletsClass RygelTrackerQueryTripletsClass;
typedef struct _RygelTrackerQueryTripletsPrivate RygelTrackerQueryTripletsPrivate;

#define RYGEL_TRACKER_TYPE_QUERY_TRIPLET (rygel_tracker_query_triplet_get_type ())
#define RYGEL_TRACKER_QUERY_TRIPLET(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), RYGEL_TRACKER_TYPE_QUERY_TRIPLET, RygelTrackerQueryTriplet))
#define RYGEL_TRACKER_QUERY_TRIPLET_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), RYGEL_TRACKER_TYPE_QUERY_TRIPLET, RygelTrackerQueryTripletClass))
#define RYGEL_TRACKER_IS_QUERY_TRIPLET(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), RYGEL_TRACKER_TYPE_QUERY_TRIPLET))
#define RYGEL_TRACKER_IS_QUERY_TRIPLET_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), RYGEL_TRACKER_TYPE_QUERY_TRIPLET))
#define RYGEL_TRACKER_QUERY_TRIPLET_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), RYGEL_TRACKER_TYPE_QUERY_TRIPLET, RygelTrackerQueryTripletClass))

typedef struct _RygelTrackerQueryTriplet RygelTrackerQueryTriplet;
typedef struct _RygelTrackerQueryTripletClass RygelTrackerQueryTripletClass;
#define _rygel_tracker_query_triplet_unref0(var) ((var == NULL) ? NULL : (var = (rygel_tracker_query_triplet_unref (var), NULL)))
#define _g_object_unref0(var) ((var == NULL) ? NULL : (var = (g_object_unref (var), NULL)))
typedef struct _RygelTrackerQueryTripletPrivate RygelTrackerQueryTripletPrivate;
#define _g_free0(var) (var = (g_free (var), NULL))

struct _RygelTrackerQueryTriplets {
	GeeArrayList parent_instance;
	RygelTrackerQueryTripletsPrivate * priv;
};

struct _RygelTrackerQueryTripletsClass {
	GeeArrayListClass parent_class;
};

struct _RygelTrackerQueryTriplet {
	GTypeInstance parent_instance;
	volatile int ref_count;
	RygelTrackerQueryTripletPrivate * priv;
	gchar* graph;
	gchar* subject;
	gchar* predicate;
	gchar* obj;
	RygelTrackerQueryTriplet* next;
};

struct _RygelTrackerQueryTripletClass {
	GTypeClass parent_class;
	void (*finalize) (RygelTrackerQueryTriplet *self);
};


static gpointer rygel_tracker_query_triplets_parent_class = NULL;

GType rygel_tracker_query_triplets_get_type (void) G_GNUC_CONST;
enum  {
	RYGEL_TRACKER_QUERY_TRIPLETS_DUMMY_PROPERTY
};
RygelTrackerQueryTriplets* rygel_tracker_query_triplets_new (void);
RygelTrackerQueryTriplets* rygel_tracker_query_triplets_construct (GType object_type);
gpointer rygel_tracker_query_triplet_ref (gpointer instance);
void rygel_tracker_query_triplet_unref (gpointer instance);
GParamSpec* rygel_tracker_param_spec_query_triplet (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags);
void rygel_tracker_value_set_query_triplet (GValue* value, gpointer v_object);
void rygel_tracker_value_take_query_triplet (GValue* value, gpointer v_object);
gpointer rygel_tracker_value_get_query_triplet (const GValue* value);
GType rygel_tracker_query_triplet_get_type (void) G_GNUC_CONST;
gboolean rygel_tracker_query_triplet_equal_func (RygelTrackerQueryTriplet* a, RygelTrackerQueryTriplet* b);
RygelTrackerQueryTriplets* rygel_tracker_query_triplets_new_clone (RygelTrackerQueryTriplets* triplets);
RygelTrackerQueryTriplets* rygel_tracker_query_triplets_construct_clone (GType object_type, RygelTrackerQueryTriplets* triplets);
RygelTrackerQueryTriplet* rygel_tracker_query_triplet_new_clone (RygelTrackerQueryTriplet* triplet);
RygelTrackerQueryTriplet* rygel_tracker_query_triplet_construct_clone (GType object_type, RygelTrackerQueryTriplet* triplet);
gchar* rygel_tracker_query_triplets_serialize (RygelTrackerQueryTriplets* self);
gchar* rygel_tracker_query_triplet_to_string (RygelTrackerQueryTriplet* self, gboolean include_subject);
static gboolean rygel_tracker_query_triplets_check_graph_change (RygelTrackerQueryTriplets* self, gint i);
static gboolean rygel_tracker_query_triplets_real_add (GeeAbstractCollection* base, RygelTrackerQueryTriplet* triplet);


RygelTrackerQueryTriplets* rygel_tracker_query_triplets_construct (GType object_type) {
	RygelTrackerQueryTriplets * self = NULL;
	self = (RygelTrackerQueryTriplets*) gee_array_list_construct (object_type, RYGEL_TRACKER_TYPE_QUERY_TRIPLET, (GBoxedCopyFunc) rygel_tracker_query_triplet_ref, rygel_tracker_query_triplet_unref, (GeeEqualDataFunc) rygel_tracker_query_triplet_equal_func, NULL, NULL);
	return self;
}


RygelTrackerQueryTriplets* rygel_tracker_query_triplets_new (void) {
	return rygel_tracker_query_triplets_construct (RYGEL_TRACKER_TYPE_QUERY_TRIPLETS);
}


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


RygelTrackerQueryTriplets* rygel_tracker_query_triplets_construct_clone (GType object_type, RygelTrackerQueryTriplets* triplets) {
	RygelTrackerQueryTriplets * self = NULL;
	g_return_val_if_fail (triplets != NULL, NULL);
	self = (RygelTrackerQueryTriplets*) gee_array_list_construct (object_type, RYGEL_TRACKER_TYPE_QUERY_TRIPLET, (GBoxedCopyFunc) rygel_tracker_query_triplet_ref, rygel_tracker_query_triplet_unref, (GeeEqualDataFunc) rygel_tracker_query_triplet_equal_func, NULL, NULL);
	{
		RygelTrackerQueryTriplets* _triplet_list = NULL;
		RygelTrackerQueryTriplets* _tmp0_ = NULL;
		RygelTrackerQueryTriplets* _tmp1_ = NULL;
		gint _triplet_size = 0;
		RygelTrackerQueryTriplets* _tmp2_ = NULL;
		gint _tmp3_ = 0;
		gint _tmp4_ = 0;
		gint _triplet_index = 0;
		_tmp0_ = triplets;
		_tmp1_ = _g_object_ref0 (_tmp0_);
		_triplet_list = _tmp1_;
		_tmp2_ = _triplet_list;
		_tmp3_ = gee_abstract_collection_get_size ((GeeCollection*) _tmp2_);
		_tmp4_ = _tmp3_;
		_triplet_size = _tmp4_;
		_triplet_index = -1;
		while (TRUE) {
			gint _tmp5_ = 0;
			gint _tmp6_ = 0;
			gint _tmp7_ = 0;
			RygelTrackerQueryTriplet* triplet = NULL;
			RygelTrackerQueryTriplets* _tmp8_ = NULL;
			gint _tmp9_ = 0;
			gpointer _tmp10_ = NULL;
			RygelTrackerQueryTriplet* _tmp11_ = NULL;
			RygelTrackerQueryTriplet* _tmp12_ = NULL;
			RygelTrackerQueryTriplet* _tmp13_ = NULL;
			_tmp5_ = _triplet_index;
			_triplet_index = _tmp5_ + 1;
			_tmp6_ = _triplet_index;
			_tmp7_ = _triplet_size;
			if (!(_tmp6_ < _tmp7_)) {
				break;
			}
			_tmp8_ = _triplet_list;
			_tmp9_ = _triplet_index;
			_tmp10_ = gee_abstract_list_get ((GeeAbstractList*) _tmp8_, _tmp9_);
			triplet = (RygelTrackerQueryTriplet*) _tmp10_;
			_tmp11_ = triplet;
			_tmp12_ = rygel_tracker_query_triplet_new_clone (_tmp11_);
			_tmp13_ = _tmp12_;
			gee_abstract_collection_add ((GeeAbstractCollection*) self, _tmp13_);
			_rygel_tracker_query_triplet_unref0 (_tmp13_);
			_rygel_tracker_query_triplet_unref0 (triplet);
		}
		_g_object_unref0 (_triplet_list);
	}
	return self;
}


RygelTrackerQueryTriplets* rygel_tracker_query_triplets_new_clone (RygelTrackerQueryTriplets* triplets) {
	return rygel_tracker_query_triplets_construct_clone (RYGEL_TRACKER_TYPE_QUERY_TRIPLETS, triplets);
}


gchar* rygel_tracker_query_triplets_serialize (RygelTrackerQueryTriplets* self) {
	gchar* result = NULL;
	gchar* str = NULL;
	gchar* _tmp0_ = NULL;
	gboolean include_subject = FALSE;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp0_ = g_strdup ("");
	str = _tmp0_;
	include_subject = TRUE;
	{
		gint i = 0;
		i = 0;
		{
			gboolean _tmp1_ = FALSE;
			_tmp1_ = TRUE;
			while (TRUE) {
				gint _tmp3_ = 0;
				gint _tmp4_ = 0;
				gint _tmp5_ = 0;
				gboolean _tmp6_ = FALSE;
				gint _tmp7_ = 0;
				gpointer _tmp8_ = NULL;
				RygelTrackerQueryTriplet* _tmp9_ = NULL;
				const gchar* _tmp10_ = NULL;
				gboolean _tmp11_ = FALSE;
				const gchar* _tmp21_ = NULL;
				gint _tmp22_ = 0;
				gpointer _tmp23_ = NULL;
				RygelTrackerQueryTriplet* _tmp24_ = NULL;
				gboolean _tmp25_ = FALSE;
				gchar* _tmp26_ = NULL;
				gchar* _tmp27_ = NULL;
				gchar* _tmp28_ = NULL;
				gint _tmp29_ = 0;
				gint _tmp30_ = 0;
				gint _tmp31_ = 0;
				if (!_tmp1_) {
					gint _tmp2_ = 0;
					_tmp2_ = i;
					i = _tmp2_ + 1;
				}
				_tmp1_ = FALSE;
				_tmp3_ = i;
				_tmp4_ = gee_abstract_collection_get_size ((GeeCollection*) self);
				_tmp5_ = _tmp4_;
				if (!(_tmp3_ < _tmp5_)) {
					break;
				}
				_tmp7_ = i;
				_tmp8_ = gee_abstract_list_get ((GeeAbstractList*) self, _tmp7_);
				_tmp9_ = (RygelTrackerQueryTriplet*) _tmp8_;
				_tmp10_ = _tmp9_->graph;
				_tmp11_ = _tmp10_ != NULL;
				_rygel_tracker_query_triplet_unref0 (_tmp9_);
				if (_tmp11_) {
					gboolean _tmp12_ = FALSE;
					_tmp12_ = include_subject;
					_tmp6_ = _tmp12_;
				} else {
					_tmp6_ = FALSE;
				}
				if (_tmp6_) {
					const gchar* _tmp13_ = NULL;
					gint _tmp14_ = 0;
					gpointer _tmp15_ = NULL;
					RygelTrackerQueryTriplet* _tmp16_ = NULL;
					const gchar* _tmp17_ = NULL;
					gchar* _tmp18_ = NULL;
					gchar* _tmp19_ = NULL;
					gchar* _tmp20_ = NULL;
					_tmp13_ = str;
					_tmp14_ = i;
					_tmp15_ = gee_abstract_list_get ((GeeAbstractList*) self, _tmp14_);
					_tmp16_ = (RygelTrackerQueryTriplet*) _tmp15_;
					_tmp17_ = _tmp16_->graph;
					_tmp18_ = g_strdup_printf ("GRAPH <%s> {", _tmp17_);
					_tmp19_ = _tmp18_;
					_tmp20_ = g_strconcat (_tmp13_, _tmp19_, NULL);
					_g_free0 (str);
					str = _tmp20_;
					_g_free0 (_tmp19_);
					_rygel_tracker_query_triplet_unref0 (_tmp16_);
				}
				_tmp21_ = str;
				_tmp22_ = i;
				_tmp23_ = gee_abstract_list_get ((GeeAbstractList*) self, _tmp22_);
				_tmp24_ = (RygelTrackerQueryTriplet*) _tmp23_;
				_tmp25_ = include_subject;
				_tmp26_ = rygel_tracker_query_triplet_to_string (_tmp24_, _tmp25_);
				_tmp27_ = _tmp26_;
				_tmp28_ = g_strconcat (_tmp21_, _tmp27_, NULL);
				_g_free0 (str);
				str = _tmp28_;
				_g_free0 (_tmp27_);
				_rygel_tracker_query_triplet_unref0 (_tmp24_);
				_tmp29_ = i;
				_tmp30_ = gee_abstract_collection_get_size ((GeeCollection*) self);
				_tmp31_ = _tmp30_;
				if (_tmp29_ < (_tmp31_ - 1)) {
					gboolean _tmp32_ = FALSE;
					gint _tmp33_ = 0;
					gpointer _tmp34_ = NULL;
					RygelTrackerQueryTriplet* _tmp35_ = NULL;
					const gchar* _tmp36_ = NULL;
					gint _tmp37_ = 0;
					gpointer _tmp38_ = NULL;
					RygelTrackerQueryTriplet* _tmp39_ = NULL;
					const gchar* _tmp40_ = NULL;
					gboolean _tmp41_ = FALSE;
					gboolean _tmp44_ = FALSE;
					_tmp33_ = i;
					_tmp34_ = gee_abstract_list_get ((GeeAbstractList*) self, _tmp33_);
					_tmp35_ = (RygelTrackerQueryTriplet*) _tmp34_;
					_tmp36_ = _tmp35_->subject;
					_tmp37_ = i;
					_tmp38_ = gee_abstract_list_get ((GeeAbstractList*) self, _tmp37_ + 1);
					_tmp39_ = (RygelTrackerQueryTriplet*) _tmp38_;
					_tmp40_ = _tmp39_->subject;
					_tmp41_ = g_strcmp0 (_tmp36_, _tmp40_) != 0;
					_rygel_tracker_query_triplet_unref0 (_tmp39_);
					_rygel_tracker_query_triplet_unref0 (_tmp35_);
					if (_tmp41_) {
						_tmp32_ = TRUE;
					} else {
						gint _tmp42_ = 0;
						gboolean _tmp43_ = FALSE;
						_tmp42_ = i;
						_tmp43_ = rygel_tracker_query_triplets_check_graph_change (self, _tmp42_);
						_tmp32_ = _tmp43_;
					}
					include_subject = _tmp32_;
					_tmp44_ = include_subject;
					if (_tmp44_) {
						const gchar* _tmp45_ = NULL;
						gchar* _tmp46_ = NULL;
						gint _tmp47_ = 0;
						gpointer _tmp48_ = NULL;
						RygelTrackerQueryTriplet* _tmp49_ = NULL;
						const gchar* _tmp50_ = NULL;
						gboolean _tmp51_ = FALSE;
						_tmp45_ = str;
						_tmp46_ = g_strconcat (_tmp45_, " . ", NULL);
						_g_free0 (str);
						str = _tmp46_;
						_tmp47_ = i;
						_tmp48_ = gee_abstract_list_get ((GeeAbstractList*) self, _tmp47_);
						_tmp49_ = (RygelTrackerQueryTriplet*) _tmp48_;
						_tmp50_ = _tmp49_->graph;
						_tmp51_ = _tmp50_ != NULL;
						_rygel_tracker_query_triplet_unref0 (_tmp49_);
						if (_tmp51_) {
							const gchar* _tmp52_ = NULL;
							gchar* _tmp53_ = NULL;
							_tmp52_ = str;
							_tmp53_ = g_strconcat (_tmp52_, "} ", NULL);
							_g_free0 (str);
							str = _tmp53_;
						}
					} else {
						const gchar* _tmp54_ = NULL;
						gchar* _tmp55_ = NULL;
						_tmp54_ = str;
						_tmp55_ = g_strconcat (_tmp54_, " ; ", NULL);
						_g_free0 (str);
						str = _tmp55_;
					}
				} else {
					gint _tmp56_ = 0;
					gpointer _tmp57_ = NULL;
					RygelTrackerQueryTriplet* _tmp58_ = NULL;
					const gchar* _tmp59_ = NULL;
					gboolean _tmp60_ = FALSE;
					_tmp56_ = i;
					_tmp57_ = gee_abstract_list_get ((GeeAbstractList*) self, _tmp56_);
					_tmp58_ = (RygelTrackerQueryTriplet*) _tmp57_;
					_tmp59_ = _tmp58_->graph;
					_tmp60_ = _tmp59_ != NULL;
					_rygel_tracker_query_triplet_unref0 (_tmp58_);
					if (_tmp60_) {
						const gchar* _tmp61_ = NULL;
						gchar* _tmp62_ = NULL;
						_tmp61_ = str;
						_tmp62_ = g_strconcat (_tmp61_, " . } ", NULL);
						_g_free0 (str);
						str = _tmp62_;
					}
				}
			}
		}
	}
	result = str;
	return result;
}


static gboolean rygel_tracker_query_triplets_real_add (GeeAbstractCollection* base, RygelTrackerQueryTriplet* triplet) {
	RygelTrackerQueryTriplets * self;
	gboolean result = FALSE;
	RygelTrackerQueryTriplet* _tmp0_ = NULL;
	gboolean _tmp1_ = FALSE;
	self = (RygelTrackerQueryTriplets*) base;
	g_return_val_if_fail (triplet != NULL, FALSE);
	_tmp0_ = triplet;
	_tmp1_ = gee_abstract_collection_contains ((GeeAbstractCollection*) self, _tmp0_);
	if (!_tmp1_) {
		RygelTrackerQueryTriplet* _tmp2_ = NULL;
		gboolean _tmp3_ = FALSE;
		_tmp2_ = triplet;
		_tmp3_ = GEE_ABSTRACT_COLLECTION_CLASS (rygel_tracker_query_triplets_parent_class)->add ((GeeAbstractCollection*) G_TYPE_CHECK_INSTANCE_CAST (self, GEE_TYPE_ARRAY_LIST, GeeArrayList), _tmp2_);
		result = _tmp3_;
		return result;
	}
	result = FALSE;
	return result;
}


static gboolean rygel_tracker_query_triplets_check_graph_change (RygelTrackerQueryTriplets* self, gint i) {
	gboolean result = FALSE;
	gboolean _tmp0_ = FALSE;
	gboolean _tmp1_ = FALSE;
	gboolean _tmp2_ = FALSE;
	gint _tmp3_ = 0;
	gpointer _tmp4_ = NULL;
	RygelTrackerQueryTriplet* _tmp5_ = NULL;
	const gchar* _tmp6_ = NULL;
	gboolean _tmp7_ = FALSE;
	g_return_val_if_fail (self != NULL, FALSE);
	_tmp3_ = i;
	_tmp4_ = gee_abstract_list_get ((GeeAbstractList*) self, _tmp3_);
	_tmp5_ = (RygelTrackerQueryTriplet*) _tmp4_;
	_tmp6_ = _tmp5_->graph;
	_tmp7_ = _tmp6_ == NULL;
	_rygel_tracker_query_triplet_unref0 (_tmp5_);
	if (_tmp7_) {
		gint _tmp8_ = 0;
		gpointer _tmp9_ = NULL;
		RygelTrackerQueryTriplet* _tmp10_ = NULL;
		const gchar* _tmp11_ = NULL;
		_tmp8_ = i;
		_tmp9_ = gee_abstract_list_get ((GeeAbstractList*) self, _tmp8_ + 1);
		_tmp10_ = (RygelTrackerQueryTriplet*) _tmp9_;
		_tmp11_ = _tmp10_->graph;
		_tmp2_ = _tmp11_ != NULL;
		_rygel_tracker_query_triplet_unref0 (_tmp10_);
	} else {
		_tmp2_ = FALSE;
	}
	if (_tmp2_) {
		_tmp1_ = TRUE;
	} else {
		gboolean _tmp12_ = FALSE;
		gint _tmp13_ = 0;
		gpointer _tmp14_ = NULL;
		RygelTrackerQueryTriplet* _tmp15_ = NULL;
		const gchar* _tmp16_ = NULL;
		gboolean _tmp17_ = FALSE;
		_tmp13_ = i;
		_tmp14_ = gee_abstract_list_get ((GeeAbstractList*) self, _tmp13_);
		_tmp15_ = (RygelTrackerQueryTriplet*) _tmp14_;
		_tmp16_ = _tmp15_->graph;
		_tmp17_ = _tmp16_ != NULL;
		_rygel_tracker_query_triplet_unref0 (_tmp15_);
		if (_tmp17_) {
			gint _tmp18_ = 0;
			gpointer _tmp19_ = NULL;
			RygelTrackerQueryTriplet* _tmp20_ = NULL;
			const gchar* _tmp21_ = NULL;
			_tmp18_ = i;
			_tmp19_ = gee_abstract_list_get ((GeeAbstractList*) self, _tmp18_ + 1);
			_tmp20_ = (RygelTrackerQueryTriplet*) _tmp19_;
			_tmp21_ = _tmp20_->graph;
			_tmp12_ = _tmp21_ == NULL;
			_rygel_tracker_query_triplet_unref0 (_tmp20_);
		} else {
			_tmp12_ = FALSE;
		}
		_tmp1_ = _tmp12_;
	}
	if (_tmp1_) {
		_tmp0_ = TRUE;
	} else {
		gint _tmp22_ = 0;
		gpointer _tmp23_ = NULL;
		RygelTrackerQueryTriplet* _tmp24_ = NULL;
		const gchar* _tmp25_ = NULL;
		gint _tmp26_ = 0;
		gpointer _tmp27_ = NULL;
		RygelTrackerQueryTriplet* _tmp28_ = NULL;
		const gchar* _tmp29_ = NULL;
		_tmp22_ = i;
		_tmp23_ = gee_abstract_list_get ((GeeAbstractList*) self, _tmp22_);
		_tmp24_ = (RygelTrackerQueryTriplet*) _tmp23_;
		_tmp25_ = _tmp24_->graph;
		_tmp26_ = i;
		_tmp27_ = gee_abstract_list_get ((GeeAbstractList*) self, _tmp26_ + 1);
		_tmp28_ = (RygelTrackerQueryTriplet*) _tmp27_;
		_tmp29_ = _tmp28_->graph;
		_tmp0_ = g_strcmp0 (_tmp25_, _tmp29_) != 0;
		_rygel_tracker_query_triplet_unref0 (_tmp28_);
		_rygel_tracker_query_triplet_unref0 (_tmp24_);
	}
	result = _tmp0_;
	return result;
}


static void rygel_tracker_query_triplets_class_init (RygelTrackerQueryTripletsClass * klass) {
	rygel_tracker_query_triplets_parent_class = g_type_class_peek_parent (klass);
	((GeeAbstractCollectionClass *) klass)->add = rygel_tracker_query_triplets_real_add;
}


static void rygel_tracker_query_triplets_instance_init (RygelTrackerQueryTriplets * self) {
}


/**
 * Represents a list of SPARQL Triplet
 */
GType rygel_tracker_query_triplets_get_type (void) {
	static volatile gsize rygel_tracker_query_triplets_type_id__volatile = 0;
	if (g_once_init_enter (&rygel_tracker_query_triplets_type_id__volatile)) {
		static const GTypeInfo g_define_type_info = { sizeof (RygelTrackerQueryTripletsClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) rygel_tracker_query_triplets_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (RygelTrackerQueryTriplets), 0, (GInstanceInitFunc) rygel_tracker_query_triplets_instance_init, NULL };
		GType rygel_tracker_query_triplets_type_id;
		rygel_tracker_query_triplets_type_id = g_type_register_static (GEE_TYPE_ARRAY_LIST, "RygelTrackerQueryTriplets", &g_define_type_info, 0);
		g_once_init_leave (&rygel_tracker_query_triplets_type_id__volatile, rygel_tracker_query_triplets_type_id);
	}
	return rygel_tracker_query_triplets_type_id__volatile;
}



