On 6/08/2013 12:07 PM, Paul Gilmartin wrote:
On Mon, 5 Aug 2013 20:52:11 -0500, Ze'ev Atlas wrote:
For subsequent releases, I may opt for two versions, one with PDS, etc. to 
accommodate you and the CBT-TAPE crowd, and the other perhaps using the Unix 
side to get more in sync with the original product and to accommodate sysprogs 
who might want to install it that way.  In any case, I do not intend (and this 
is  pledge!) to abandon the old classic z/OS.

fopen() will handle fopen( "//'data.set.name(member)'" ) and
fopen( "/UNIX/path/name" ) alike.  open() only the UNIX path.
So if you intend to support Classic data sets you are constrained
to use fopen().  Then handling UNIX paths is no additional code.

I've always liked the nice abstraction with the z/OS C/C++ FILE I/O implementation. fopen() is a factory function which returns a semi-opaque structure with two function pointers to read/write routines (methods) which handle all the different access methods (QSAM, BSAM, VSAM, UNIX, Hiperspaces etc). It's a good design and an example of OO done well in C using pointers in structs ;).

(Of course this constrains your users to those respective syntactic
forms. But you need some way of distinguishing the two species,
and the C RTL convention is as good as any.)

-- gil

----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN

----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN

Reply via email to