[C++, 2.0] IF we need I_Stream ?

Ruslan Zasukhin sunshine at public.kherson.ua
Wed Oct 22 19:23:18 CDT 2003


on 10/22/03 18:52, Maxim Shevchenko at mshevchenko at kiev.ua.ddlabs.com wrote:

Hi Maxim,

> Hi all!
> Streams - I say: why not?
> * Some libraries (such as VCL or wxWindows) has own streams that
> represents I/O operation. I suppose it is a good style.
> In common streams represented the high-level I/O wrappers and every
> developer should avoid to uses low-level I/O API directly but use only
> appropriate I/O stream objects. The main goal of the streams is hide
> low-level I/O API calls from the library user.

Correct, but please note, wxWindows hide behind Streams the OS Low Level
API, while we already have in C++ SDK such wrapper of OS API -- I_File
classes.

So for our C++ SDK stream will not play role of wrapper of OS.

> * Besides, some additional I/O features can be implemented, such as
> serialization and deserialization of the complex objects and so on.

THIS IS GOOD POINT!

Ivan also have point this just only:
-- we can talk about putting into stream Column of table, Table,
    or in general case -- Cursor.

> Also even, if we need only a couple of streams yet (SocketStream,
> BLOBStream) we need the base interfaces (I_Stream, I_InputStream,
> I_OutputStream) to be declared because we can widen the streams library
> in future in case when more streams becomes necessary.

Also agree.

Look, for now I am not sure IF we need InputStream / OutputStream
subclasses...may be just Istream...But let's try to live with them.

> We can also use the streams with all kind of fields (not only BLOB).

In what way?

Maxim, I will send you also our sources of Stream classes that we have use
in Vserver. 


> -----Original Message-----
> From: Ruslan Zasukhin [mailto:sunshine at public.kherson.ua]
> Sent: Tuesday, October 21, 2003 11:41 PM
> To: Totte Alm; Maxim Shevchenko; Jochen Peters;
> valentina at lists.macserve.net
> Subject: [C++, 2.0] IF we need I_Stream ?
> 
> Hi All C++ developers,
> 
> I want get advice from you.
> 
> Now we consider adding of interfaces
>   I_Stream
>   I_InputStream
>   I_OutputStream
>   
> To API of 2.0 C++ SDK.
> 
>> From one side this can be useful...from other side I still not see very
> strong reasons to do this...So may be somebody of you can show me that
> reasons.
> 
> * Right now we have use stream only in Vserver as wrapper to SOCKET.
> 
> * Also I see potential ability to use streams in BLOB fields as second
> way
> to access BLOB data. The benefit of stream here that we can read even by
> one
> byte. And we can not worry about tmp buffer...although this reduce speed
> I
> think. 
> 
> Anybody have see any other usage of streams in some DB SDK?
> Or may be have ideas where we can use streams?

-- 
Best regards,
Ruslan Zasukhin      [ I feel the need...the need for speed ]
-------------------------------------------------------------
e-mail: ruslan at paradigmasoft.com
web: http://www.paradigmasoft.com

To subscribe to the Valentina mail list go to:
http://lists.macserve.net/mailman/listinfo/valentina
-------------------------------------------------------------



More information about the Valentina mailing list