Re: Plans for gnome-vfs replacement

On Sun, 2006-09-24 at 14:51 +0200, Philip Van Hoof wrote:


Search and replace issue.  This should of course be something like:

((inst), G_TYPE_INPUT_STREAM, GInputStreamIface))


And this one GSeekableIface

Also note that I would definitely start with a base GStreamIface,
continue with a GInputStreamIface and a GOutputStreamIface where the
input and output have as prerequisite the GStreamIface.

Or in .NET (and Java) that would mean: 

namespace G {
 interface IStreamIface { .. }
 interface IOutputStream : G.IStreamIface { .. }
 interface IInputStream : G.IStreamIface { .. }
 interface ISeekable : G.IStreamIface { .. } 
 /* OR: interface ISeekable { .. }; */

In Java I think you can only extend an interface with one interface.
In .NET I know you can extend an interface with as much other interfaces
as you want.

Extending an interface is more or less the exact same thing as copy
pasting all the to-implement methods and properties (properties
translate to both a get and a set method in Java, depends on whether or
not it's a read-only property etc etc) in the final interface.

And now you would create a SomeStreamType like this:

public class SomeStreamType : G.IOutputStream, G.IInputStream, G.ISeekable

ps. To the Java warriors on this list: forgive me for my .NET style
syntax. I know you guys know it's all the same (Java and .NET) with just
a little bit different syntax sugar.

Philip Van Hoof, software developer at x-tend 
home: me at pvanhoof dot be 
gnome: pvanhoof at gnome dot org 
work: vanhoof at x-tend dot be -

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