GIOChannels, GNet, GOIO



Hi!

I want to bring Bug#106686 [0] up to dicsussion again. I like the idea
of having an GObject-based IO system quite a lot and think it would be
a worthwhile attempt to unify GIOChannel, GOIO (see [0] and [1]) and
the GNet library. Since I need a more flexibility than offered by
GNet+GIOChannel, I'm willing to invest some effort to get this
started. I have the following in mind (as needed for my project):

1) Add an aynchronous facility ala GIOChannel watches to GOIO
2) Provide a callback-based GConn-like interface above that
3) "Port" GTcpSocket to GOIO

For those interested, the problem I need to solve is: I have a GConn,
using gnet_conn_readn(). After a certain amount of reads, I want to
switch to "bare" asynchronous operation on the underlying IOChannel
(using watches). I need to do the watch stuff since I have a
multiplexer that operates on GIOChannels -- the problem I have is that
the GConn does separate buffering.

Also, this would solve the shortcoming of GNet that you can't use
GConn-callback style IO on e.g. UNIX domain sockets (GConn is
hardwired with a GTcpSocket), since the GConn-style interface provided
in 2) will be able to be stacked above every object that implements
GoioWatchable.

Thoughts?

[0] http://bugzilla.gnome.org/show_bug.cgi?id=106686
[1] http://thread.gmane.org/gmane.comp.gnome.gtk+.devel.general/4984

Andy
-- 
Andreas Rottmann         | Rotty ICQ      | 118634484 ICQ | a rottmann gmx at
http://yi.org/rotty      | GnuPG Key: http://yi.org/rotty/gpg.asc
Fingerprint              | DFB4 4EB4 78A4 5EEE 6219  F228 F92F CFC5 01FD 5B62

It's *GNU*/Linux dammit!




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