From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-1.3 required=5.0 tests=BAYES_00,INVALID_MSGID autolearn=no autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,8fb5bdcb507b36df X-Google-Attributes: gid103376,public From: jerry@jvdsys.nextjk.stuyts.nl (Jerry van Dijk) Subject: Re: Win32 File Handles and Ada Date: 1998/05/31 Message-ID: #1/1 X-Deja-AN: 358404448 References: <3570933D.50780D04@roanoke.infi.net> Organization: * JerryWare *, Leiden, Holland Newsgroups: comp.lang.ada Date: 1998-05-31T00:00:00+00:00 List-Id: Srinivasan, R (gitas@roanoke.infi.net) wrote: : Environment : Win NT 4.0 : I am looking for a way to map Win32 File handles - created by CreatePipe : for instance into Ada Text_Io.File_Type (or some other such construct : that is close). You invoke quite a number of issues here... 1) The Ada.Text_IO.File_Type is a limited private type, how it is defined depends on you particular Ada Runtime Library Environment. Most likely, it will be different for all compilation systems. You seem to assume that File_Type will be a File Handle. This might or might not be true. 2) a Win32 File Handle can be many things, like a Windows Handle, a C type file handle or file descriptor, but also a Asynchronous Windows Handle that acts like a C file descriptor... You have to be absolutely clear on what you are talking about here. What your question seems to be is: How can I use the Text_IO functions and procedures to read and write on Win32 pipes. which is a different question. The answer is: you implement them on top of the Win32 binding. For an example you could take a peek at my Win32 port of AdaSockets, which does a simular thing for reading/writing through sockets. The source is at http://stad.dsl.nl/~jvandyk Jerry. -- -- Jerry van Dijk | email: jdijk@acm.org -- Leiden, Holland | member Team-Ada