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.9 required=5.0 tests=BAYES_00 autolearn=ham autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,7624df5e57d09688 X-Google-Attributes: gid103376,public X-Google-ArrivalTime: 2002-06-09 13:17:00 PST Path: archiver1.google.com!news1.google.com!newsfeed.stanford.edu!headwall.stanford.edu!newsfeed-west.nntpserver.com!hub1.meganetnews.com!nntpserver.com!DirecTVinternet!DirecTV-DSL!news-out.spamkiller.net!propagator2-maxim!propagator-maxim!news-in.spamkiller.net!border1.nntp.aus1.giganews.com!nntp.giganews.com!nntp3.aus1.giganews.com!bin8.nnrp.aus1.giganews.com.POSTED!not-for-mail Sender: Stephe@TAKVER Newsgroups: comp.lang.ada Subject: Re: config files proposal References: <3CFA8E42.B7844253@san.rr.com> <3CFAEEB5.CE3041C2@san.rr.com> From: Stephen Leake Message-ID: User-Agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.1 MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii NNTP-Posting-Date: Sun, 09 Jun 2002 15:16:42 CDT Organization: Giganews.Com - Premium News Outsourcing X-Trace: sv3-DoFZFrvbG7eSJ1KO8JNkfcP8d/+fzl/5CNjphSIi6ob4wDtbMlMVAKdiHPGyBkMGfMeTIGcoWo4lDAF!efca5ET7l8RJCq5rAhVtMf7RniuYzwR6abRvEQt7GzE= X-Complaints-To: abuse@comcast.com X-DMCA-Complaints-To: dmca@comcast.net X-Abuse-Info: Please be sure to forward a copy of ALL headers X-Abuse-Info: Otherwise we will be unable to process your complaint properly Date: Sun, 09 Jun 2002 20:16:42 GMT Xref: archiver1.google.com comp.lang.ada:25618 Date: 2002-06-09T20:16:42+00:00 List-Id: Darren New writes: > Stephen Leake wrote: > > > You need to specify where a file is written in the path. (API#6) > > > apparently only talks about reading files. > > > > It should be written where it is found; I'll add that. Hmm, special > > case if it is a new file; write it to the first directory in the > > search path. > > The problem here is if you load a system-wide config file, make changes, and > want to save it. You at least need a routine that says "pretend you got it > from *here*" or something; i.e., to change the name&path of the file between > reading and writing. Good point. I guess I can check the write privs on the found file. Or provide two search paths; one read-only and one writeable. > > > Question: Are keys case-sensitive? > > > > Good point. I think I'll go with the Ada identifier model and say > > "no". > > If "no" and you're allowing Unicode, then you have to worry about the > bizarre transformations that some languages have. yes. And Glib.XML is case sensitive. Although Glib.XML also uses String for Tags, not Wide_String. So I have to check the XML definition; does it allow Wide_String for tags? Hmm. http://www.w3.org/TR/2000/REC-xml-20001006#NT-Letter seems to imply 16 bit characters, but I'm not clear on whether it's UniCode or something else. There's also the issue of what Wide_Text_IO actually writes. > > base64 would be good for values that don't need to be user editable. I > > guess persistent storage for a large object (whether it is composite > > or not) could be supported that way. I'm not clear why that would be > > in a typical "config file". Hmm, maybe a pixel bitmap for an icon? > > That was actually my thought, yes. Funky how we both had the same example in > mind. Yes. However, a better solution for bitmaps is to keep the bitmap in a file that a bitmap editor will recognize, and put the path to it (possibly relative) in the config file. But we don't need to _forbid_ binary data in the config file, if it's not hard to do. -- -- Stephe