]> git.ipfire.org Git - thirdparty/vala.git/commitdiff
gstreamer-0.10: make GstIterator a generic
authorEvan Nemerson <evan@coeus-group.com>
Fri, 9 Apr 2010 10:04:43 +0000 (03:04 -0700)
committerEvan Nemerson <evan@coeus-group.com>
Fri, 9 Apr 2010 10:04:43 +0000 (03:04 -0700)
vapi/gstreamer-0.10.vapi
vapi/packages/gstreamer-0.10/gstreamer-0.10.metadata

index 1d79120559eefc8fdd473276c0e2fef7a77ac0d6..94316d6e5164999cce7d31f0fa8e3946f7754f6c 100644 (file)
@@ -390,7 +390,7 @@ namespace Gst {
                public class void install_std_props (...);
                public bool is_indexable ();
                public bool is_locked_state ();
-               public Gst.Iterator iterate_pads ();
+               public Gst.Iterator<Gst.Pad> iterate_pads ();
                public Gst.Iterator iterate_sink_pads ();
                public Gst.Iterator iterate_src_pads ();
                public bool link (Gst.Element dest);
@@ -604,7 +604,7 @@ namespace Gst {
        }
        [Compact]
        [CCode (cheader_filename = "gst/gst.h")]
-       public class Iterator {
+       public class Iterator<T> {
                public uint32 cookie;
                public weak GLib.Mutex @lock;
                public void* master_cookie;
@@ -612,16 +612,16 @@ namespace Gst {
                public GLib.Type type;
                [CCode (has_construct_function = false)]
                public Iterator (uint size, GLib.Type type, GLib.Mutex @lock, ref uint32 master_cookie, Gst.IteratorNextFunction next, Gst.IteratorItemFunction item, Gst.IteratorResyncFunction resync, Gst.IteratorFreeFunction free);
-               public void* find_custom (GLib.CompareFunc func);
+               public T find_custom (GLib.CompareFunc func, T user_data);
                public Gst.IteratorResult fold ([CCode (delegate_target_pos = 2.1)] Gst.IteratorFoldFunction func, Gst.Value? ret);
                public Gst.IteratorResult @foreach (GLib.Func func);
                [CCode (has_construct_function = false)]
-               public Iterator.list (GLib.Type type, GLib.Mutex @lock, ref uint32 master_cookie, GLib.List list, void* owner, Gst.IteratorItemFunction item, Gst.IteratorDisposeFunction free);
-               public Gst.IteratorResult next (out void* elem);
+               public Iterator.list (GLib.Type type, GLib.Mutex @lock, ref uint32 master_cookie, GLib.List<T> list, void* owner, Gst.IteratorItemFunction item, Gst.IteratorDisposeFunction free);
+               public Gst.IteratorResult next (out T elem);
                public void push (Gst.Iterator other);
                public void resync ();
                [CCode (has_construct_function = false)]
-               public Iterator.single (GLib.Type type, void* object, Gst.CopyFunction copy, GLib.FreeFunc free);
+               public Iterator.single (GLib.Type type, T object, Gst.CopyFunction copy, GLib.FreeFunc free);
        }
        [CCode (ref_function = "gst_message_ref", unref_function = "gst_message_unref", cheader_filename = "gst/gst.h")]
        public class Message : Gst.MiniObject {
index f516fe91404a35c273622ff095b451cd33a0e700..0ce94ab32b0b33f495a744131ebffdb26b4f68db 100644 (file)
@@ -171,6 +171,7 @@ gst_element_factory_create.name nullable="1"
 gst_element_factory_get_static_pad_templates type_arguments="StaticPadTemplate"
 gst_element_factory_find transfer_ownership="1" nullable="1"
 gst_element_factory_get_uri_protocols is_array="1" array_null_terminated="1" transfer_ownership="1" nullable="1"
+gst_element_iterate_pads transfer_ownership="1" type_arguments="Pad"
 gst_error_get_message transfer_ownership="1"
 GstEvent base_class="GstMiniObject"
 GstEvent.mini_object hidden="1"
@@ -225,19 +226,22 @@ gst_init_get_option_group transfer_ownership="1"
 gst_index_factory_make transfer_ownership="1" nullable="1"
 gst_index_factory_create transfer_ownership="1"
 gst_index_factory_find transfer_ownership="1" nullable="1"
+GstIterator type_parameters="T"
 GstIterator.free hidden="1"
 GstIterator.next hidden="1"
 GstIterator.resync hidden="1"
 GstIterator.item hidden="1"
 GstIterator.pushed nullable="1"
 GstIterator.master_cookie type_name="pointer"
-gst_iterator_next.elem is_out="1"
+gst_iterator_next.elem type_name="T" is_out="1" transfer_ownership="1"
 gst_iterator_fold.func delegate_target_pos="2.1"
 gst_iterator_fold.ret nullable="1"
-gst_iterator_find_custom.user_data hidden="0"
+gst_iterator_new_list.list type_arguments="T"
 gst_iterator_new.master_cookie is_ref="1"
 gst_iterator_new_list.master_cookie is_ref="1"
-gst_iterator_find_custom.user_data hidden="1"
+gst_iterator_find_custom type_name="T" transfer_ownership="1"
+gst_iterator_find_custom.user_data type_name="T" hidden="0"
+gst_iterator_new_single.object type_name="T"
 gst_iterator_filter hidden="1"
 GstIteratorNextFunction.result is_out="1"
 GstIteratorFoldFunction.ret is_ref="1"