Re: [Vala] Interface static method



my question is simple : How implement static method c interface ?

Yet I have no idea what you are trying to do. Are you trying to implement URIHandler interface in Vala?

An exemple with GStreamer URIHandler :
http://cgit.freedesktop.org/gstreamer/gstreamer/tree/gst/gsturi.h

get_protocols member has "2 types" : 1 in interface structure and the other
as method.

the get_protocols method is a convenience function that "just" calls the function pointer in the structure. For GObject interfaces, you don't have to do anything about that.

If you want to implement this interface in vala, you just "override" the method because it is abstract and Vala does the rest of the magic.




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]