/* streamiterator.c generated by valac 0.25.3.11-62b1e, the Vala compiler
 * generated from streamiterator.vala, do not modify */

/* streamiterator.vala
 *
 * Copyright (C) 2013  Maciej Piechotka
 *
 * This library 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.

 * This library 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
 *
 * Author:
 * 	Maciej Piechotka <uzytkownik2@gmail.com>
 */

#include <glib.h>
#include <glib-object.h>


#define GEE_TYPE_TRAVERSABLE (gee_traversable_get_type ())
#define GEE_TRAVERSABLE(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), GEE_TYPE_TRAVERSABLE, GeeTraversable))
#define GEE_IS_TRAVERSABLE(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), GEE_TYPE_TRAVERSABLE))
#define GEE_TRAVERSABLE_GET_INTERFACE(obj) (G_TYPE_INSTANCE_GET_INTERFACE ((obj), GEE_TYPE_TRAVERSABLE, GeeTraversableIface))

typedef struct _GeeTraversable GeeTraversable;
typedef struct _GeeTraversableIface GeeTraversableIface;

#define GEE_TRAVERSABLE_TYPE_STREAM (gee_traversable_stream_get_type ())

#define GEE_TYPE_LAZY (gee_lazy_get_type ())
#define GEE_LAZY(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), GEE_TYPE_LAZY, GeeLazy))
#define GEE_LAZY_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), GEE_TYPE_LAZY, GeeLazyClass))
#define GEE_IS_LAZY(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), GEE_TYPE_LAZY))
#define GEE_IS_LAZY_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), GEE_TYPE_LAZY))
#define GEE_LAZY_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), GEE_TYPE_LAZY, GeeLazyClass))

typedef struct _GeeLazy GeeLazy;
typedef struct _GeeLazyClass GeeLazyClass;

#define GEE_TYPE_ITERATOR (gee_iterator_get_type ())
#define GEE_ITERATOR(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), GEE_TYPE_ITERATOR, GeeIterator))
#define GEE_IS_ITERATOR(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), GEE_TYPE_ITERATOR))
#define GEE_ITERATOR_GET_INTERFACE(obj) (G_TYPE_INSTANCE_GET_INTERFACE ((obj), GEE_TYPE_ITERATOR, GeeIteratorIface))

typedef struct _GeeIterator GeeIterator;
typedef struct _GeeIteratorIface GeeIteratorIface;

#define GEE_TYPE_STREAM_ITERATOR (gee_stream_iterator_get_type ())
#define GEE_STREAM_ITERATOR(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), GEE_TYPE_STREAM_ITERATOR, GeeStreamIterator))
#define GEE_STREAM_ITERATOR_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), GEE_TYPE_STREAM_ITERATOR, GeeStreamIteratorClass))
#define GEE_IS_STREAM_ITERATOR(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), GEE_TYPE_STREAM_ITERATOR))
#define GEE_IS_STREAM_ITERATOR_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), GEE_TYPE_STREAM_ITERATOR))
#define GEE_STREAM_ITERATOR_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), GEE_TYPE_STREAM_ITERATOR, GeeStreamIteratorClass))

typedef struct _GeeStreamIterator GeeStreamIterator;
typedef struct _GeeStreamIteratorClass GeeStreamIteratorClass;
typedef struct _GeeStreamIteratorPrivate GeeStreamIteratorPrivate;
#define _g_object_unref0(var) ((var == NULL) ? NULL : (var = (g_object_unref (var), NULL)))
#define _gee_lazy_unref0(var) ((var == NULL) ? NULL : (var = (gee_lazy_unref (var), NULL)))
typedef struct _Block12Data Block12Data;
#define _vala_assert(expr, msg) if G_LIKELY (expr) ; else g_assertion_message_expr (G_LOG_DOMAIN, __FILE__, __LINE__, G_STRFUNC, msg);

typedef gboolean (*GeeForallFunc) (gpointer g, void* user_data);
typedef enum  {
	GEE_TRAVERSABLE_STREAM_YIELD,
	GEE_TRAVERSABLE_STREAM_CONTINUE,
	GEE_TRAVERSABLE_STREAM_END,
	GEE_TRAVERSABLE_STREAM_WAIT
} GeeTraversableStream;

typedef GeeTraversableStream (*GeeStreamFunc) (GeeTraversableStream state, GeeLazy* g, GeeLazy** lazy, void* user_data);
struct _GeeIteratorIface {
	GTypeInterface parent_iface;
	gboolean (*next) (GeeIterator* self);
	gboolean (*has_next) (GeeIterator* self);
	gpointer (*get) (GeeIterator* self);
	void (*remove) (GeeIterator* self);
	gboolean (*get_valid) (GeeIterator* self);
	gboolean (*get_read_only) (GeeIterator* self);
};

typedef gpointer (*GeeFoldFunc) (gpointer g, gpointer a, void* user_data);
typedef gpointer (*GeeMapFunc) (gpointer g, void* user_data);
typedef gboolean (*GeePredicate) (gconstpointer g, void* user_data);
typedef GeeIterator* (*GeeFlatMapFunc) (gpointer g, void* user_data);
struct _GeeTraversableIface {
	GTypeInterface parent_iface;
	GType (*get_g_type) (GeeTraversable* self);
	GBoxedCopyFunc (*get_g_dup_func) (GeeTraversable* self);
	GDestroyNotify (*get_g_destroy_func) (GeeTraversable* self);
	gboolean (*foreach) (GeeTraversable* self, GeeForallFunc f, void* f_target);
	GeeIterator* (*stream) (GeeTraversable* self, GType a_type, GBoxedCopyFunc a_dup_func, GDestroyNotify a_destroy_func, GeeStreamFunc f, void* f_target, GDestroyNotify f_target_destroy_notify);
	gpointer (*fold) (GeeTraversable* self, GType a_type, GBoxedCopyFunc a_dup_func, GDestroyNotify a_destroy_func, GeeFoldFunc f, void* f_target, gpointer seed);
	GeeIterator* (*map) (GeeTraversable* self, GType a_type, GBoxedCopyFunc a_dup_func, GDestroyNotify a_destroy_func, GeeMapFunc f, void* f_target);
	GeeIterator* (*scan) (GeeTraversable* self, GType a_type, GBoxedCopyFunc a_dup_func, GDestroyNotify a_destroy_func, GeeFoldFunc f, void* f_target, gpointer seed);
	GeeIterator* (*filter) (GeeTraversable* self, GeePredicate pred, void* pred_target, GDestroyNotify pred_target_destroy_notify);
	GeeIterator* (*chop) (GeeTraversable* self, gint offset, gint length);
	GType (*get_element_type) (GeeTraversable* self);
	GeeIterator* (*flat_map) (GeeTraversable* self, GType a_type, GBoxedCopyFunc a_dup_func, GDestroyNotify a_destroy_func, GeeFlatMapFunc f, void* f_target, GDestroyNotify f_target_destroy_notify);
	GeeIterator** (*tee) (GeeTraversable* self, guint forks, int* result_length1);
};

struct _GeeStreamIterator {
	GObject parent_instance;
	GeeStreamIteratorPrivate * priv;
};

struct _GeeStreamIteratorClass {
	GObjectClass parent_class;
};

struct _GeeStreamIteratorPrivate {
	GType a_type;
	GBoxedCopyFunc a_dup_func;
	GDestroyNotify a_destroy_func;
	GType g_type;
	GBoxedCopyFunc g_dup_func;
	GDestroyNotify g_destroy_func;
	GeeIterator* _outer;
	GeeStreamFunc _func;
	gpointer _func_target;
	GDestroyNotify _func_target_destroy_notify;
	GeeLazy* _outer_value;
	GeeLazy* _current;
	GeeLazy* _next;
	GeeTraversableStream _state;
	gboolean _need_next;
	gboolean _finished;
};

typedef gpointer (*GeeLazyFunc) (void* user_data);
struct _Block12Data {
	int _ref_count_;
	GType a_type;
	GBoxedCopyFunc a_dup_func;
	GDestroyNotify a_destroy_func;
	GType g_type;
	GBoxedCopyFunc g_dup_func;
	GDestroyNotify g_destroy_func;
	GeeIterator* outer;
};


static gpointer gee_stream_iterator_parent_class = NULL;
static GeeTraversableIface* gee_stream_iterator_gee_traversable_parent_iface = NULL;
static GeeIteratorIface* gee_stream_iterator_gee_iterator_parent_iface = NULL;

GType gee_traversable_stream_get_type (void) G_GNUC_CONST;
gpointer gee_lazy_ref (gpointer instance);
void gee_lazy_unref (gpointer instance);
GParamSpec* gee_param_spec_lazy (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags);
void gee_value_set_lazy (GValue* value, gpointer v_object);
void gee_value_take_lazy (GValue* value, gpointer v_object);
gpointer gee_value_get_lazy (const GValue* value);
GType gee_lazy_get_type (void) G_GNUC_CONST;
GType gee_iterator_get_type (void) G_GNUC_CONST;
GType gee_traversable_get_type (void) G_GNUC_CONST;
G_GNUC_INTERNAL GType gee_stream_iterator_get_type (void) G_GNUC_CONST G_GNUC_UNUSED;
#define GEE_STREAM_ITERATOR_GET_PRIVATE(o) (G_TYPE_INSTANCE_GET_PRIVATE ((o), GEE_TYPE_STREAM_ITERATOR, GeeStreamIteratorPrivate))
enum  {
	GEE_STREAM_ITERATOR_DUMMY_PROPERTY,
	GEE_STREAM_ITERATOR_A_TYPE,
	GEE_STREAM_ITERATOR_A_DUP_FUNC,
	GEE_STREAM_ITERATOR_A_DESTROY_FUNC,
	GEE_STREAM_ITERATOR_G_TYPE,
	GEE_STREAM_ITERATOR_G_DUP_FUNC,
	GEE_STREAM_ITERATOR_G_DESTROY_FUNC,
	GEE_STREAM_ITERATOR_VALID,
	GEE_STREAM_ITERATOR_READ_ONLY
};
G_GNUC_INTERNAL GeeStreamIterator* gee_stream_iterator_new (GType a_type, GBoxedCopyFunc a_dup_func, GDestroyNotify a_destroy_func, GType g_type, GBoxedCopyFunc g_dup_func, GDestroyNotify g_destroy_func, GeeIterator* outer, GeeStreamFunc func, void* func_target, GDestroyNotify func_target_destroy_notify);
G_GNUC_INTERNAL GeeStreamIterator* gee_stream_iterator_construct (GType object_type, GType a_type, GBoxedCopyFunc a_dup_func, GDestroyNotify a_destroy_func, GType g_type, GBoxedCopyFunc g_dup_func, GDestroyNotify g_destroy_func, GeeIterator* outer, GeeStreamFunc func, void* func_target, GDestroyNotify func_target_destroy_notify);
gboolean gee_iterator_get_valid (GeeIterator* self);
static gpointer ____lambda8_ (GeeStreamIterator* self);
gpointer gee_iterator_get (GeeIterator* self);
static gpointer _____lambda8__gee_lazy_func (gpointer self);
GeeLazy* gee_lazy_new (GType g_type, GBoxedCopyFunc g_dup_func, GDestroyNotify g_destroy_func, GeeLazyFunc func, void* func_target, GDestroyNotify func_target_destroy_notify);
GeeLazy* gee_lazy_construct (GType object_type, GType g_type, GBoxedCopyFunc g_dup_func, GDestroyNotify g_destroy_func, GeeLazyFunc func, void* func_target, GDestroyNotify func_target_destroy_notify);
static gboolean gee_stream_iterator_real_foreach (GeeTraversable* base, GeeForallFunc f, void* f_target);
gconstpointer gee_lazy_get_value (GeeLazy* self);
static inline GeeLazy* gee_stream_iterator_yield_next (GType a_type, GBoxedCopyFunc a_dup_func, GDestroyNotify a_destroy_func, GType g_type, GBoxedCopyFunc g_dup_func, GDestroyNotify g_destroy_func, GeeIterator* outer, GeeStreamFunc func, void* func_target, GeeTraversableStream* state, gboolean* need_next, GeeLazy** outer_value);
static gboolean gee_stream_iterator_real_next (GeeIterator* base);
gboolean gee_iterator_has_next (GeeIterator* self);
void gee_lazy_eval (GeeLazy* self);
static gboolean gee_stream_iterator_real_has_next (GeeIterator* base);
static gpointer gee_stream_iterator_real_get (GeeIterator* base);
static void gee_stream_iterator_real_remove (GeeIterator* base);
static Block12Data* block12_data_ref (Block12Data* _data12_);
static void block12_data_unref (void * _userdata_);
static gpointer _____lambda9_ (Block12Data* _data12_);
gboolean gee_iterator_next (GeeIterator* self);
static gpointer ______lambda9__gee_lazy_func (gpointer self);
static gpointer _____lambda10_ (Block12Data* _data12_);
static gpointer ______lambda10__gee_lazy_func (gpointer self);
static void gee_stream_iterator_finalize (GObject* obj);
gboolean gee_iterator_get_read_only (GeeIterator* self);
static void _vala_gee_stream_iterator_get_property (GObject * object, guint property_id, GValue * value, GParamSpec * pspec);
static void _vala_gee_stream_iterator_set_property (GObject * object, guint property_id, const GValue * value, GParamSpec * pspec);


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


static gpointer ____lambda8_ (GeeStreamIterator* self) {
	gpointer result = NULL;
	GeeIterator* _tmp0_ = NULL;
	gpointer _tmp1_ = NULL;
	_tmp0_ = self->priv->_outer;
	_tmp1_ = gee_iterator_get (_tmp0_);
	result = _tmp1_;
	return result;
}


static gpointer _____lambda8__gee_lazy_func (gpointer self) {
	gpointer result;
	result = ____lambda8_ ((GeeStreamIterator*) self);
	return result;
}


G_GNUC_INTERNAL GeeStreamIterator* gee_stream_iterator_construct (GType object_type, GType a_type, GBoxedCopyFunc a_dup_func, GDestroyNotify a_destroy_func, GType g_type, GBoxedCopyFunc g_dup_func, GDestroyNotify g_destroy_func, GeeIterator* outer, GeeStreamFunc func, void* func_target, GDestroyNotify func_target_destroy_notify) {
	GeeStreamIterator * self = NULL;
	GeeIterator* _tmp0_ = NULL;
	GeeIterator* _tmp1_ = NULL;
	GeeStreamFunc _tmp2_ = NULL;
	void* _tmp2__target = NULL;
	GDestroyNotify _tmp2__target_destroy_notify = NULL;
	GeeStreamFunc _tmp3_ = NULL;
	void* _tmp3__target = NULL;
	GeeLazy* _tmp4_ = NULL;
	GeeTraversableStream _tmp5_ = 0;
	GeeTraversableStream _tmp6_ = 0;
	g_return_val_if_fail (outer != NULL, NULL);
	self = (GeeStreamIterator*) g_object_new (object_type, NULL);
	self->priv->a_type = a_type;
	self->priv->a_dup_func = a_dup_func;
	self->priv->a_destroy_func = a_destroy_func;
	self->priv->g_type = g_type;
	self->priv->g_dup_func = g_dup_func;
	self->priv->g_destroy_func = g_destroy_func;
	_tmp0_ = outer;
	_tmp1_ = _g_object_ref0 (_tmp0_);
	_g_object_unref0 (self->priv->_outer);
	self->priv->_outer = _tmp1_;
	_tmp2_ = func;
	_tmp2__target = func_target;
	_tmp2__target_destroy_notify = func_target_destroy_notify;
	func_target_destroy_notify = NULL;
	(self->priv->_func_target_destroy_notify == NULL) ? NULL : (self->priv->_func_target_destroy_notify (self->priv->_func_target), NULL);
	self->priv->_func = NULL;
	self->priv->_func_target = NULL;
	self->priv->_func_target_destroy_notify = NULL;
	self->priv->_func = _tmp2_;
	self->priv->_func_target = _tmp2__target;
	self->priv->_func_target_destroy_notify = _tmp2__target_destroy_notify;
	_gee_lazy_unref0 (self->priv->_current);
	self->priv->_current = NULL;
	self->priv->_need_next = TRUE;
	self->priv->_finished = FALSE;
	_tmp3_ = self->priv->_func;
	_tmp3__target = self->priv->_func_target;
	_tmp5_ = _tmp3_ (GEE_TRAVERSABLE_STREAM_YIELD, NULL, &_tmp4_, _tmp3__target);
	_gee_lazy_unref0 (self->priv->_current);
	self->priv->_current = _tmp4_;
	self->priv->_state = _tmp5_;
	_tmp6_ = self->priv->_state;
	switch (_tmp6_) {
		case GEE_TRAVERSABLE_STREAM_WAIT:
		case GEE_TRAVERSABLE_STREAM_YIELD:
		{
			GeeIterator* _tmp7_ = NULL;
			gboolean _tmp8_ = FALSE;
			gboolean _tmp9_ = FALSE;
			_tmp7_ = self->priv->_outer;
			_tmp8_ = gee_iterator_get_valid (_tmp7_);
			_tmp9_ = _tmp8_;
			self->priv->_need_next = !_tmp9_;
			break;
		}
		case GEE_TRAVERSABLE_STREAM_CONTINUE:
		{
			GeeIterator* _tmp10_ = NULL;
			gboolean _tmp11_ = FALSE;
			gboolean _tmp12_ = FALSE;
			_tmp10_ = self->priv->_outer;
			_tmp11_ = gee_iterator_get_valid (_tmp10_);
			_tmp12_ = _tmp11_;
			if (_tmp12_) {
				GeeStreamFunc _tmp13_ = NULL;
				void* _tmp13__target = NULL;
				GeeTraversableStream _tmp14_ = 0;
				GeeLazy* _tmp15_ = NULL;
				GeeLazy* _tmp16_ = NULL;
				GeeTraversableStream _tmp17_ = 0;
				GeeTraversableStream _tmp18_ = 0;
				_tmp13_ = self->priv->_func;
				_tmp13__target = self->priv->_func_target;
				_tmp14_ = self->priv->_state;
				_tmp15_ = gee_lazy_new (g_type, (GBoxedCopyFunc) g_dup_func, g_destroy_func, _____lambda8__gee_lazy_func, g_object_ref (self), g_object_unref);
				_tmp17_ = _tmp13_ (_tmp14_, _tmp15_, &_tmp16_, _tmp13__target);
				_gee_lazy_unref0 (self->priv->_current);
				self->priv->_current = _tmp16_;
				self->priv->_state = _tmp17_;
				_tmp18_ = self->priv->_state;
				switch (_tmp18_) {
					case GEE_TRAVERSABLE_STREAM_YIELD:
					case GEE_TRAVERSABLE_STREAM_CONTINUE:
					case GEE_TRAVERSABLE_STREAM_WAIT:
					{
						break;
					}
					case GEE_TRAVERSABLE_STREAM_END:
					{
						self->priv->_finished = TRUE;
						(func_target_destroy_notify == NULL) ? NULL : (func_target_destroy_notify (func_target), NULL);
						func = NULL;
						func_target = NULL;
						func_target_destroy_notify = NULL;
						return self;
					}
					default:
					{
						g_assert_not_reached ();
					}
				}
			}
			break;
		}
		case GEE_TRAVERSABLE_STREAM_END:
		{
			self->priv->_finished = TRUE;
			(func_target_destroy_notify == NULL) ? NULL : (func_target_destroy_notify (func_target), NULL);
			func = NULL;
			func_target = NULL;
			func_target_destroy_notify = NULL;
			return self;
		}
		default:
		break;
	}
	(func_target_destroy_notify == NULL) ? NULL : (func_target_destroy_notify (func_target), NULL);
	func = NULL;
	func_target = NULL;
	func_target_destroy_notify = NULL;
	return self;
}


G_GNUC_INTERNAL GeeStreamIterator* gee_stream_iterator_new (GType a_type, GBoxedCopyFunc a_dup_func, GDestroyNotify a_destroy_func, GType g_type, GBoxedCopyFunc g_dup_func, GDestroyNotify g_destroy_func, GeeIterator* outer, GeeStreamFunc func, void* func_target, GDestroyNotify func_target_destroy_notify) {
	return gee_stream_iterator_construct (GEE_TYPE_STREAM_ITERATOR, a_type, a_dup_func, a_destroy_func, g_type, g_dup_func, g_destroy_func, outer, func, func_target, func_target_destroy_notify);
}


static gpointer _gee_lazy_ref0 (gpointer self) {
	return self ? gee_lazy_ref (self) : NULL;
}


static gboolean gee_stream_iterator_real_foreach (GeeTraversable* base, GeeForallFunc f, void* f_target) {
	GeeStreamIterator * self;
	gboolean result = FALSE;
	GeeLazy* current = NULL;
	GeeLazy* _tmp0_ = NULL;
	GeeLazy* _tmp7_ = NULL;
	GeeIterator* outer = NULL;
	GeeIterator* _tmp16_ = NULL;
	GeeStreamFunc func = NULL;
	GeeStreamFunc _tmp17_ = NULL;
	void* _tmp17__target = NULL;
	void* func_target = NULL;
	GeeTraversableStream state = 0;
	GeeTraversableStream _tmp18_ = 0;
	gboolean need_next = FALSE;
	gboolean _tmp19_ = FALSE;
	gboolean _result_ = FALSE;
	GeeLazy* next_current = NULL;
	GeeLazy* outer_value = NULL;
	GeeLazy* _tmp20_ = NULL;
	GeeLazy* _tmp21_ = NULL;
	GeeTraversableStream _tmp33_ = 0;
	gboolean _tmp34_ = FALSE;
	gboolean _tmp35_ = FALSE;
	GeeLazy* _tmp36_ = NULL;
	GeeLazy* _tmp37_ = NULL;
	self = (GeeStreamIterator*) base;
	current = NULL;
	_tmp0_ = self->priv->_current;
	if (_tmp0_ != NULL) {
		GeeForallFunc _tmp1_ = NULL;
		void* _tmp1__target = NULL;
		GeeLazy* _tmp2_ = NULL;
		gconstpointer _tmp3_ = NULL;
		gconstpointer _tmp4_ = NULL;
		gpointer _tmp5_ = NULL;
		gboolean _tmp6_ = FALSE;
		_tmp1_ = f;
		_tmp1__target = f_target;
		_tmp2_ = self->priv->_current;
		_tmp3_ = gee_lazy_get_value (_tmp2_);
		_tmp4_ = _tmp3_;
		_tmp5_ = ((_tmp4_ != NULL) && (self->priv->a_dup_func != NULL)) ? self->priv->a_dup_func ((gpointer) _tmp4_) : ((gpointer) _tmp4_);
		_tmp6_ = _tmp1_ (_tmp5_, _tmp1__target);
		if (!_tmp6_) {
			result = FALSE;
			_gee_lazy_unref0 (current);
			return result;
		}
	}
	_tmp7_ = self->priv->_next;
	if (_tmp7_ != NULL) {
		GeeLazy* _tmp8_ = NULL;
		GeeForallFunc _tmp9_ = NULL;
		void* _tmp9__target = NULL;
		GeeLazy* _tmp10_ = NULL;
		gconstpointer _tmp11_ = NULL;
		gconstpointer _tmp12_ = NULL;
		gpointer _tmp13_ = NULL;
		gboolean _tmp14_ = FALSE;
		_tmp8_ = self->priv->_next;
		self->priv->_next = NULL;
		_gee_lazy_unref0 (current);
		current = _tmp8_;
		_tmp9_ = f;
		_tmp9__target = f_target;
		_tmp10_ = current;
		_tmp11_ = gee_lazy_get_value (_tmp10_);
		_tmp12_ = _tmp11_;
		_tmp13_ = ((_tmp12_ != NULL) && (self->priv->a_dup_func != NULL)) ? self->priv->a_dup_func ((gpointer) _tmp12_) : ((gpointer) _tmp12_);
		_tmp14_ = _tmp9_ (_tmp13_, _tmp9__target);
		if (!_tmp14_) {
			result = FALSE;
			_gee_lazy_unref0 (current);
			return result;
		}
	} else {
		gboolean _tmp15_ = FALSE;
		_tmp15_ = self->priv->_finished;
		if (_tmp15_) {
			result = TRUE;
			_gee_lazy_unref0 (current);
			return result;
		}
	}
	_tmp16_ = self->priv->_outer;
	outer = _tmp16_;
	_tmp17_ = self->priv->_func;
	_tmp17__target = self->priv->_func_target;
	func = _tmp17_;
	func_target = _tmp17__target;
	_tmp18_ = self->priv->_state;
	state = _tmp18_;
	_tmp19_ = self->priv->_need_next;
	need_next = _tmp19_;
	_result_ = TRUE;
	_tmp20_ = self->priv->_outer_value;
	_tmp21_ = _gee_lazy_ref0 (_tmp20_);
	outer_value = _tmp21_;
	while (TRUE) {
		GeeIterator* _tmp22_ = NULL;
		GeeStreamFunc _tmp23_ = NULL;
		void* _tmp23__target = NULL;
		GeeLazy* _tmp24_ = NULL;
		GeeLazy* _tmp25_ = NULL;
		GeeLazy* _tmp26_ = NULL;
		GeeForallFunc _tmp27_ = NULL;
		void* _tmp27__target = NULL;
		GeeLazy* _tmp28_ = NULL;
		gconstpointer _tmp29_ = NULL;
		gconstpointer _tmp30_ = NULL;
		gpointer _tmp31_ = NULL;
		gboolean _tmp32_ = FALSE;
		_tmp22_ = outer;
		_tmp23_ = func;
		_tmp23__target = func_target;
		_tmp24_ = gee_stream_iterator_yield_next (self->priv->a_type, (GBoxedCopyFunc) self->priv->a_dup_func, self->priv->a_destroy_func, self->priv->g_type, (GBoxedCopyFunc) self->priv->g_dup_func, self->priv->g_destroy_func, _tmp22_, _tmp23_, _tmp23__target, &state, &need_next, &outer_value);
		_gee_lazy_unref0 (next_current);
		next_current = _tmp24_;
		_tmp25_ = next_current;
		if (!(_tmp25_ != NULL)) {
			break;
		}
		_tmp26_ = next_current;
		next_current = NULL;
		_gee_lazy_unref0 (current);
		current = _tmp26_;
		_tmp27_ = f;
		_tmp27__target = f_target;
		_tmp28_ = current;
		_tmp29_ = gee_lazy_get_value (_tmp28_);
		_tmp30_ = _tmp29_;
		_tmp31_ = ((_tmp30_ != NULL) && (self->priv->a_dup_func != NULL)) ? self->priv->a_dup_func ((gpointer) _tmp30_) : ((gpointer) _tmp30_);
		_tmp32_ = _tmp27_ (_tmp31_, _tmp27__target);
		if (!_tmp32_) {
			_result_ = FALSE;
			break;
		}
	}
	_tmp33_ = state;
	self->priv->_state = _tmp33_;
	_tmp34_ = need_next;
	self->priv->_need_next = _tmp34_;
	_tmp35_ = _result_;
	self->priv->_finished = _tmp35_;
	_tmp36_ = current;
	current = NULL;
	_gee_lazy_unref0 (self->priv->_current);
	self->priv->_current = _tmp36_;
	_tmp37_ = outer_value;
	outer_value = NULL;
	_gee_lazy_unref0 (self->priv->_outer_value);
	self->priv->_outer_value = _tmp37_;
	result = _result_;
	_gee_lazy_unref0 (outer_value);
	_gee_lazy_unref0 (next_current);
	_gee_lazy_unref0 (current);
	return result;
}


static gboolean gee_stream_iterator_real_next (GeeIterator* base) {
	GeeStreamIterator * self;
	gboolean result = FALSE;
	gboolean _tmp0_ = FALSE;
	self = (GeeStreamIterator*) base;
	_tmp0_ = gee_iterator_has_next ((GeeIterator*) self);
	if (_tmp0_) {
		GeeLazy* _tmp1_ = NULL;
		GeeLazy* _tmp3_ = NULL;
		_tmp1_ = self->priv->_current;
		if (_tmp1_ != NULL) {
			GeeLazy* _tmp2_ = NULL;
			_tmp2_ = self->priv->_current;
			gee_lazy_eval (_tmp2_);
		}
		_tmp3_ = self->priv->_next;
		self->priv->_next = NULL;
		_gee_lazy_unref0 (self->priv->_current);
		self->priv->_current = _tmp3_;
		result = TRUE;
		return result;
	} else {
		result = FALSE;
		return result;
	}
}


static gboolean gee_stream_iterator_real_has_next (GeeIterator* base) {
	GeeStreamIterator * self;
	gboolean result = FALSE;
	gboolean _tmp0_ = FALSE;
	GeeLazy* _tmp1_ = NULL;
	GeeIterator* _tmp2_ = NULL;
	GeeStreamFunc _tmp3_ = NULL;
	void* _tmp3__target = NULL;
	GeeLazy* _tmp4_ = NULL;
	GeeLazy* _tmp5_ = NULL;
	gboolean _tmp6_ = FALSE;
	self = (GeeStreamIterator*) base;
	_tmp0_ = self->priv->_finished;
	if (_tmp0_) {
		result = FALSE;
		return result;
	}
	_tmp1_ = self->priv->_next;
	if (_tmp1_ != NULL) {
		result = TRUE;
		return result;
	}
	_tmp2_ = self->priv->_outer;
	_tmp3_ = self->priv->_func;
	_tmp3__target = self->priv->_func_target;
	_tmp4_ = gee_stream_iterator_yield_next (self->priv->a_type, (GBoxedCopyFunc) self->priv->a_dup_func, self->priv->a_destroy_func, self->priv->g_type, (GBoxedCopyFunc) self->priv->g_dup_func, self->priv->g_destroy_func, _tmp2_, _tmp3_, _tmp3__target, &self->priv->_state, &self->priv->_need_next, &self->priv->_outer_value);
	_gee_lazy_unref0 (self->priv->_next);
	self->priv->_next = _tmp4_;
	_tmp5_ = self->priv->_next;
	self->priv->_finished = _tmp5_ == NULL;
	_tmp6_ = self->priv->_finished;
	result = !_tmp6_;
	return result;
}


static gpointer gee_stream_iterator_real_get (GeeIterator* base) {
	GeeStreamIterator * self;
	gpointer result = NULL;
	GeeLazy* _tmp0_ = NULL;
	GeeLazy* _tmp1_ = NULL;
	gconstpointer _tmp2_ = NULL;
	gconstpointer _tmp3_ = NULL;
	gpointer _tmp4_ = NULL;
	self = (GeeStreamIterator*) base;
	_tmp0_ = self->priv->_current;
	_vala_assert (_tmp0_ != NULL, "_current != null");
	_tmp1_ = self->priv->_current;
	_tmp2_ = gee_lazy_get_value (_tmp1_);
	_tmp3_ = _tmp2_;
	_tmp4_ = ((_tmp3_ != NULL) && (self->priv->a_dup_func != NULL)) ? self->priv->a_dup_func ((gpointer) _tmp3_) : ((gpointer) _tmp3_);
	result = _tmp4_;
	return result;
}


static void gee_stream_iterator_real_remove (GeeIterator* base) {
	GeeStreamIterator * self;
	self = (GeeStreamIterator*) base;
	g_assert_not_reached ();
}


static Block12Data* block12_data_ref (Block12Data* _data12_) {
	g_atomic_int_inc (&_data12_->_ref_count_);
	return _data12_;
}


static void block12_data_unref (void * _userdata_) {
	Block12Data* _data12_;
	_data12_ = (Block12Data*) _userdata_;
	if (g_atomic_int_dec_and_test (&_data12_->_ref_count_)) {
		GType a_type;
		GBoxedCopyFunc a_dup_func;
		GDestroyNotify a_destroy_func;
		GType g_type;
		GBoxedCopyFunc g_dup_func;
		GDestroyNotify g_destroy_func;
		a_type = _data12_->a_type;
		a_dup_func = _data12_->a_dup_func;
		a_destroy_func = _data12_->a_destroy_func;
		g_type = _data12_->g_type;
		g_dup_func = _data12_->g_dup_func;
		g_destroy_func = _data12_->g_destroy_func;
		_g_object_unref0 (_data12_->outer);
		g_slice_free (Block12Data, _data12_);
	}
}


static gpointer _____lambda9_ (Block12Data* _data12_) {
	GType a_type;
	GBoxedCopyFunc a_dup_func;
	GDestroyNotify a_destroy_func;
	GType g_type;
	GBoxedCopyFunc g_dup_func;
	GDestroyNotify g_destroy_func;
	gpointer result = NULL;
	GeeIterator* _tmp0_ = NULL;
	gboolean _tmp1_ = FALSE;
	GeeIterator* _tmp2_ = NULL;
	gpointer _tmp3_ = NULL;
	a_type = _data12_->a_type;
	a_dup_func = _data12_->a_dup_func;
	a_destroy_func = _data12_->a_destroy_func;
	g_type = _data12_->g_type;
	g_dup_func = _data12_->g_dup_func;
	g_destroy_func = _data12_->g_destroy_func;
	_tmp0_ = _data12_->outer;
	_tmp1_ = gee_iterator_next (_tmp0_);
	_vala_assert (_tmp1_, "outer.next ()");
	_tmp2_ = _data12_->outer;
	_tmp3_ = gee_iterator_get (_tmp2_);
	result = _tmp3_;
	return result;
}


static gpointer ______lambda9__gee_lazy_func (gpointer self) {
	gpointer result;
	result = _____lambda9_ (self);
	return result;
}


static gpointer _____lambda10_ (Block12Data* _data12_) {
	GType a_type;
	GBoxedCopyFunc a_dup_func;
	GDestroyNotify a_destroy_func;
	GType g_type;
	GBoxedCopyFunc g_dup_func;
	GDestroyNotify g_destroy_func;
	gpointer result = NULL;
	GeeIterator* _tmp0_ = NULL;
	gpointer _tmp1_ = NULL;
	a_type = _data12_->a_type;
	a_dup_func = _data12_->a_dup_func;
	a_destroy_func = _data12_->a_destroy_func;
	g_type = _data12_->g_type;
	g_dup_func = _data12_->g_dup_func;
	g_destroy_func = _data12_->g_destroy_func;
	_tmp0_ = _data12_->outer;
	_tmp1_ = gee_iterator_get (_tmp0_);
	result = _tmp1_;
	return result;
}


static gpointer ______lambda10__gee_lazy_func (gpointer self) {
	gpointer result;
	result = _____lambda10_ (self);
	return result;
}


static inline GeeLazy* gee_stream_iterator_yield_next (GType a_type, GBoxedCopyFunc a_dup_func, GDestroyNotify a_destroy_func, GType g_type, GBoxedCopyFunc g_dup_func, GDestroyNotify g_destroy_func, GeeIterator* outer, GeeStreamFunc func, void* func_target, GeeTraversableStream* state, gboolean* need_next, GeeLazy** outer_value) {
	GeeLazy* result = NULL;
	Block12Data* _data12_;
	GeeIterator* _tmp0_ = NULL;
	GeeIterator* _tmp1_ = NULL;
	GeeLazy* value = NULL;
	GeeTraversableStream _tmp2_ = 0;
	g_return_val_if_fail (outer != NULL, NULL);
	_data12_ = g_slice_new0 (Block12Data);
	_data12_->_ref_count_ = 1;
	_data12_->a_type = a_type;
	_data12_->a_dup_func = a_dup_func;
	_data12_->a_destroy_func = a_destroy_func;
	_data12_->g_type = g_type;
	_data12_->g_dup_func = g_dup_func;
	_data12_->g_destroy_func = g_destroy_func;
	_tmp0_ = outer;
	_tmp1_ = _g_object_ref0 (_tmp0_);
	_g_object_unref0 (_data12_->outer);
	_data12_->outer = _tmp1_;
	value = NULL;
	_tmp2_ = *state;
	if (_tmp2_ != GEE_TRAVERSABLE_STREAM_CONTINUE) {
		GeeStreamFunc _tmp3_ = NULL;
		void* _tmp3__target = NULL;
		GeeTraversableStream _tmp4_ = 0;
		GeeLazy* _tmp5_ = NULL;
		GeeTraversableStream _tmp6_ = 0;
		_tmp3_ = func;
		_tmp3__target = func_target;
		_tmp4_ = *state;
		_tmp6_ = _tmp3_ (_tmp4_, NULL, &_tmp5_, _tmp3__target);
		_gee_lazy_unref0 (value);
		value = _tmp5_;
		*state = _tmp6_;
	}
	while (TRUE) {
		GeeTraversableStream _tmp7_ = 0;
		_tmp7_ = *state;
		switch (_tmp7_) {
			case GEE_TRAVERSABLE_STREAM_YIELD:
			{
				result = value;
				block12_data_unref (_data12_);
				_data12_ = NULL;
				return result;
			}
			case GEE_TRAVERSABLE_STREAM_CONTINUE:
			{
				GeeLazy* _tmp8_ = NULL;
				gboolean _tmp10_ = FALSE;
				GeeStreamFunc _tmp18_ = NULL;
				void* _tmp18__target = NULL;
				GeeTraversableStream _tmp19_ = 0;
				GeeLazy* _tmp20_ = NULL;
				GeeLazy* _tmp21_ = NULL;
				GeeLazy* _tmp22_ = NULL;
				GeeTraversableStream _tmp23_ = 0;
				_tmp8_ = *outer_value;
				if (_tmp8_ != NULL) {
					GeeLazy* _tmp9_ = NULL;
					_tmp9_ = *outer_value;
					gee_lazy_eval (_tmp9_);
				}
				_tmp10_ = *need_next;
				if (_tmp10_) {
					GeeIterator* _tmp11_ = NULL;
					gboolean _tmp12_ = FALSE;
					GeeLazy* _tmp16_ = NULL;
					_tmp11_ = _data12_->outer;
					_tmp12_ = gee_iterator_has_next (_tmp11_);
					if (!_tmp12_) {
						GeeStreamFunc _tmp13_ = NULL;
						void* _tmp13__target = NULL;
						GeeLazy* _tmp14_ = NULL;
						GeeTraversableStream _tmp15_ = 0;
						_tmp13_ = func;
						_tmp13__target = func_target;
						_tmp15_ = _tmp13_ (GEE_TRAVERSABLE_STREAM_END, NULL, &_tmp14_, _tmp13__target);
						_gee_lazy_unref0 (value);
						value = _tmp14_;
						*state = _tmp15_;
						continue;
					}
					_tmp16_ = gee_lazy_new (g_type, (GBoxedCopyFunc) g_dup_func, g_destroy_func, ______lambda9__gee_lazy_func, block12_data_ref (_data12_), block12_data_unref);
					_gee_lazy_unref0 (*outer_value);
					*outer_value = _tmp16_;
				} else {
					GeeLazy* _tmp17_ = NULL;
					*need_next = TRUE;
					_tmp17_ = gee_lazy_new (g_type, (GBoxedCopyFunc) g_dup_func, g_destroy_func, ______lambda10__gee_lazy_func, block12_data_ref (_data12_), block12_data_unref);
					_gee_lazy_unref0 (*outer_value);
					*outer_value = _tmp17_;
				}
				_tmp18_ = func;
				_tmp18__target = func_target;
				_tmp19_ = *state;
				_tmp20_ = *outer_value;
				_tmp21_ = _gee_lazy_ref0 (_tmp20_);
				_tmp23_ = _tmp18_ (_tmp19_, _tmp21_, &_tmp22_, _tmp18__target);
				_gee_lazy_unref0 (value);
				value = _tmp22_;
				*state = _tmp23_;
				break;
			}
			case GEE_TRAVERSABLE_STREAM_WAIT:
			{
				GeeStreamFunc _tmp24_ = NULL;
				void* _tmp24__target = NULL;
				GeeTraversableStream _tmp25_ = 0;
				GeeLazy* _tmp26_ = NULL;
				GeeTraversableStream _tmp27_ = 0;
				_tmp24_ = func;
				_tmp24__target = func_target;
				_tmp25_ = *state;
				_tmp27_ = _tmp24_ (_tmp25_, NULL, &_tmp26_, _tmp24__target);
				_gee_lazy_unref0 (value);
				value = _tmp26_;
				*state = _tmp27_;
				break;
			}
			case GEE_TRAVERSABLE_STREAM_END:
			{
				result = NULL;
				_gee_lazy_unref0 (value);
				block12_data_unref (_data12_);
				_data12_ = NULL;
				return result;
			}
			default:
			{
				g_assert_not_reached ();
			}
		}
	}
	_gee_lazy_unref0 (value);
	block12_data_unref (_data12_);
	_data12_ = NULL;
}


static gboolean gee_stream_iterator_real_get_valid (GeeIterator* base) {
	gboolean result;
	GeeStreamIterator* self;
	GeeLazy* _tmp0_ = NULL;
	self = (GeeStreamIterator*) base;
	_tmp0_ = self->priv->_current;
	result = _tmp0_ != NULL;
	return result;
}


static gboolean gee_stream_iterator_real_get_read_only (GeeIterator* base) {
	gboolean result;
	GeeStreamIterator* self;
	self = (GeeStreamIterator*) base;
	result = TRUE;
	return result;
}


static void gee_stream_iterator_class_init (GeeStreamIteratorClass * klass) {
	gee_stream_iterator_parent_class = g_type_class_peek_parent (klass);
	g_type_class_add_private (klass, sizeof (GeeStreamIteratorPrivate));
	G_OBJECT_CLASS (klass)->get_property = _vala_gee_stream_iterator_get_property;
	G_OBJECT_CLASS (klass)->set_property = _vala_gee_stream_iterator_set_property;
	G_OBJECT_CLASS (klass)->finalize = gee_stream_iterator_finalize;
	g_object_class_install_property (G_OBJECT_CLASS (klass), GEE_STREAM_ITERATOR_A_TYPE, g_param_spec_gtype ("a-type", "type", "type", G_TYPE_NONE, G_PARAM_STATIC_NAME | G_PARAM_STATIC_NICK | G_PARAM_STATIC_BLURB | G_PARAM_WRITABLE | G_PARAM_CONSTRUCT_ONLY));
	g_object_class_install_property (G_OBJECT_CLASS (klass), GEE_STREAM_ITERATOR_A_DUP_FUNC, g_param_spec_pointer ("a-dup-func", "dup func", "dup func", G_PARAM_STATIC_NAME | G_PARAM_STATIC_NICK | G_PARAM_STATIC_BLURB | G_PARAM_WRITABLE | G_PARAM_CONSTRUCT_ONLY));
	g_object_class_install_property (G_OBJECT_CLASS (klass), GEE_STREAM_ITERATOR_A_DESTROY_FUNC, g_param_spec_pointer ("a-destroy-func", "destroy func", "destroy func", G_PARAM_STATIC_NAME | G_PARAM_STATIC_NICK | G_PARAM_STATIC_BLURB | G_PARAM_WRITABLE | G_PARAM_CONSTRUCT_ONLY));
	g_object_class_install_property (G_OBJECT_CLASS (klass), GEE_STREAM_ITERATOR_G_TYPE, g_param_spec_gtype ("g-type", "type", "type", G_TYPE_NONE, G_PARAM_STATIC_NAME | G_PARAM_STATIC_NICK | G_PARAM_STATIC_BLURB | G_PARAM_WRITABLE | G_PARAM_CONSTRUCT_ONLY));
	g_object_class_install_property (G_OBJECT_CLASS (klass), GEE_STREAM_ITERATOR_G_DUP_FUNC, g_param_spec_pointer ("g-dup-func", "dup func", "dup func", G_PARAM_STATIC_NAME | G_PARAM_STATIC_NICK | G_PARAM_STATIC_BLURB | G_PARAM_WRITABLE | G_PARAM_CONSTRUCT_ONLY));
	g_object_class_install_property (G_OBJECT_CLASS (klass), GEE_STREAM_ITERATOR_G_DESTROY_FUNC, g_param_spec_pointer ("g-destroy-func", "destroy func", "destroy func", G_PARAM_STATIC_NAME | G_PARAM_STATIC_NICK | G_PARAM_STATIC_BLURB | G_PARAM_WRITABLE | G_PARAM_CONSTRUCT_ONLY));
	g_object_class_install_property (G_OBJECT_CLASS (klass), GEE_STREAM_ITERATOR_VALID, g_param_spec_boolean ("valid", "valid", "valid", FALSE, G_PARAM_STATIC_NAME | G_PARAM_STATIC_NICK | G_PARAM_STATIC_BLURB | G_PARAM_READABLE));
	g_object_class_install_property (G_OBJECT_CLASS (klass), GEE_STREAM_ITERATOR_READ_ONLY, g_param_spec_boolean ("read-only", "read-only", "read-only", FALSE, G_PARAM_STATIC_NAME | G_PARAM_STATIC_NICK | G_PARAM_STATIC_BLURB | G_PARAM_READABLE));
}


static GType gee_stream_iterator_gee_traversable_get_g_type (GeeStreamIterator* self) {
	return self->priv->a_type;
}


static GBoxedCopyFunc gee_stream_iterator_gee_traversable_get_g_dup_func (GeeStreamIterator* self) {
	return self->priv->a_dup_func;
}


static GDestroyNotify gee_stream_iterator_gee_traversable_get_g_destroy_func (GeeStreamIterator* self) {
	return self->priv->a_destroy_func;
}


static void gee_stream_iterator_gee_traversable_interface_init (GeeTraversableIface * iface) {
	gee_stream_iterator_gee_traversable_parent_iface = g_type_interface_peek_parent (iface);
	iface->foreach = (gboolean (*)(GeeTraversable*, GeeForallFunc, void*)) gee_stream_iterator_real_foreach;
	iface->get_g_type = (GType(*)(GeeTraversable*)) gee_stream_iterator_gee_traversable_get_g_type;
	iface->get_g_dup_func = (GBoxedCopyFunc(*)(GeeTraversable*)) gee_stream_iterator_gee_traversable_get_g_dup_func;
	iface->get_g_destroy_func = (GDestroyNotify(*)(GeeTraversable*)) gee_stream_iterator_gee_traversable_get_g_destroy_func;
}


static void gee_stream_iterator_gee_iterator_interface_init (GeeIteratorIface * iface) {
	gee_stream_iterator_gee_iterator_parent_iface = g_type_interface_peek_parent (iface);
	iface->next = (gboolean (*)(GeeIterator*)) gee_stream_iterator_real_next;
	iface->has_next = (gboolean (*)(GeeIterator*)) gee_stream_iterator_real_has_next;
	iface->get = (gpointer (*)(GeeIterator*)) gee_stream_iterator_real_get;
	iface->remove = (void (*)(GeeIterator*)) gee_stream_iterator_real_remove;
	iface->get_valid = gee_stream_iterator_real_get_valid;
	iface->get_read_only = gee_stream_iterator_real_get_read_only;
}


static void gee_stream_iterator_instance_init (GeeStreamIterator * self) {
	self->priv = GEE_STREAM_ITERATOR_GET_PRIVATE (self);
}


static void gee_stream_iterator_finalize (GObject* obj) {
	GeeStreamIterator * self;
	self = G_TYPE_CHECK_INSTANCE_CAST (obj, GEE_TYPE_STREAM_ITERATOR, GeeStreamIterator);
	_g_object_unref0 (self->priv->_outer);
	(self->priv->_func_target_destroy_notify == NULL) ? NULL : (self->priv->_func_target_destroy_notify (self->priv->_func_target), NULL);
	self->priv->_func = NULL;
	self->priv->_func_target = NULL;
	self->priv->_func_target_destroy_notify = NULL;
	_gee_lazy_unref0 (self->priv->_outer_value);
	_gee_lazy_unref0 (self->priv->_current);
	_gee_lazy_unref0 (self->priv->_next);
	G_OBJECT_CLASS (gee_stream_iterator_parent_class)->finalize (obj);
}


G_GNUC_INTERNAL GType gee_stream_iterator_get_type (void) {
	static volatile gsize gee_stream_iterator_type_id__volatile = 0;
	if (g_once_init_enter (&gee_stream_iterator_type_id__volatile)) {
		static const GTypeInfo g_define_type_info = { sizeof (GeeStreamIteratorClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) gee_stream_iterator_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (GeeStreamIterator), 0, (GInstanceInitFunc) gee_stream_iterator_instance_init, NULL };
		static const GInterfaceInfo gee_traversable_info = { (GInterfaceInitFunc) gee_stream_iterator_gee_traversable_interface_init, (GInterfaceFinalizeFunc) NULL, NULL};
		static const GInterfaceInfo gee_iterator_info = { (GInterfaceInitFunc) gee_stream_iterator_gee_iterator_interface_init, (GInterfaceFinalizeFunc) NULL, NULL};
		GType gee_stream_iterator_type_id;
		gee_stream_iterator_type_id = g_type_register_static (G_TYPE_OBJECT, "GeeStreamIterator", &g_define_type_info, 0);
		g_type_add_interface_static (gee_stream_iterator_type_id, GEE_TYPE_TRAVERSABLE, &gee_traversable_info);
		g_type_add_interface_static (gee_stream_iterator_type_id, GEE_TYPE_ITERATOR, &gee_iterator_info);
		g_once_init_leave (&gee_stream_iterator_type_id__volatile, gee_stream_iterator_type_id);
	}
	return gee_stream_iterator_type_id__volatile;
}


static void _vala_gee_stream_iterator_get_property (GObject * object, guint property_id, GValue * value, GParamSpec * pspec) {
	GeeStreamIterator * self;
	self = G_TYPE_CHECK_INSTANCE_CAST (object, GEE_TYPE_STREAM_ITERATOR, GeeStreamIterator);
	switch (property_id) {
		case GEE_STREAM_ITERATOR_VALID:
		g_value_set_boolean (value, gee_iterator_get_valid ((GeeIterator*) self));
		break;
		case GEE_STREAM_ITERATOR_READ_ONLY:
		g_value_set_boolean (value, gee_iterator_get_read_only ((GeeIterator*) self));
		break;
		default:
		G_OBJECT_WARN_INVALID_PROPERTY_ID (object, property_id, pspec);
		break;
	}
}


static void _vala_gee_stream_iterator_set_property (GObject * object, guint property_id, const GValue * value, GParamSpec * pspec) {
	GeeStreamIterator * self;
	self = G_TYPE_CHECK_INSTANCE_CAST (object, GEE_TYPE_STREAM_ITERATOR, GeeStreamIterator);
	switch (property_id) {
		case GEE_STREAM_ITERATOR_A_TYPE:
		self->priv->a_type = g_value_get_gtype (value);
		break;
		case GEE_STREAM_ITERATOR_A_DUP_FUNC:
		self->priv->a_dup_func = g_value_get_pointer (value);
		break;
		case GEE_STREAM_ITERATOR_A_DESTROY_FUNC:
		self->priv->a_destroy_func = g_value_get_pointer (value);
		break;
		case GEE_STREAM_ITERATOR_G_TYPE:
		self->priv->g_type = g_value_get_gtype (value);
		break;
		case GEE_STREAM_ITERATOR_G_DUP_FUNC:
		self->priv->g_dup_func = g_value_get_pointer (value);
		break;
		case GEE_STREAM_ITERATOR_G_DESTROY_FUNC:
		self->priv->g_destroy_func = g_value_get_pointer (value);
		break;
		default:
		G_OBJECT_WARN_INVALID_PROPERTY_ID (object, property_id, pspec);
		break;
	}
}



