comp.lang.ada
 help / color / mirror / Atom feed
From: anon@anon.org (anon)
Subject: Re: Ada.Directories problems, a summary
Date: Thu, 01 Jan 2009 20:41:28 GMT
Date: 2009-01-01T20:41:28+00:00	[thread overview]
Message-ID: <YT97l.249008$Mh5.169688@bgtnsc04-news.ops.worldnet.att.net> (raw)
In-Reply-To: 17rohiaha9ome$.1gz45no0bqro2.dlg@40tude.net


    1. OS problem. Name encoding must match OS and file system that being 
       used. And that may be different between locations or OSs.

    2. OS problem, that all programming languages have to deal with.

    3. No need. The usage is just as easy as using a Alphanumeric 
       directory names. And traversing the directory tree is more portable
       since more current file system use "." and "..". It is also, easy
       to check and skip them while going deeper within a directory tree.
       Note, most file search routines understand how to deal with these 
       two special directories.

    4. Another standards OS problem. Drives are not directories in Windows 
       and DOS. And this includes some embedded OS. Actually most Windows 
       uses wish that MS would replace the DOS drive letters with "/" 
       directory structure because of the internet usage of "/".

    5. Windows and it's apps designs loves Popups. This is a MS problem 
       not Ada or GNAT.

    6. Another OS problem. If a drive is not ready, is it a "drive not mounted"
       or is there a problem with the drive such as a "drive crash".  So, this 
       not useful, in Ada.Directories or any file type package ( Ada.Direct_IO, 
       Ada.Sequential_IO, or Ada.Text_IO ). The drive should be installed and 
       mounted before Ada even tries to access any file or directory routine. 

       Since, most current computers system have CD/DVD and USB ports 
       that allow Flash or external drives. Ada needs an Ada.OS_Library for 
       common and standard routines that can handle mounting or hardware
       problems. In this package, the program could ask if a drive is 
       mounted or is the drive working proper.  Or the program could 
       request for a drive aka CD/DVD to be inserted. Of course this would 
       mean another Windows popup screen.

    7. Not a standard concept in all file systems or OSs and may be phase out
       completely. For some OS, its a security option (allowing duplicate files 
       for simple file backup concept, etc), that should be handled by an 
       Security package. For Windows, the version numbers are used as one 
       way to allow floppies to use long file names under the MS FAT files 
       structure.  But as flash drives (using FS which uses long file names 
       structure) replace floppies so it seams that MS will phase out the use 
       of the version numbers design. Maybe VMS should too.

       So, the only thing that you have stated that may alter Ada is the one 
that causes an Ada.OS_library package. To determine rather a drive is 
mounted or has crashed. And another routine to mount a drive.


In <17rohiaha9ome$.1gz45no0bqro2.dlg@40tude.net>, "Dmitry A. Kazakov" <mailbox@dmitry-kazakov.de> writes:
>After experimenting with Ada.Directories I collected the issues I think
>must be addressed to make Ada.Directories more usable:
>
>1. Name encoding. Either String versions should be UTF-8 or else replaced
>with Wide_Wide_String ones.
>
>2. Name canonization / comparison functions. Presently it is impossible to
>compare files by names because the same file may have potentially an
>infinite number of names.
>
>3. Fake children "." and ".." should have special File_Kind
>(Virtual_Directory_File, for example). Else it is impossible to traverse
>the directory tree in a portable way.
>
>4. There should be a variant of Start_Search without the Directory
>parameter, in order to enumerate the roots of the file systems. For
>example, to find drive letters under Windows, network shares, mount points
>etc.
>
>5. The behavior of Exists must be specified for the case of mountable
>volumes. Presently GNAT implementation pops a message box under Windows.
>This should be outlawed.
>
>6. Is_Mountable / Is_Removable functions should be provided.
>
>7. Version number in addition to Containing_Directory, Base_Name and
>Extension. (Files have version numbers under VMS)
>
>Any comments?
>
>P.S. Happy New Year!
>
>-- 
>Regards,
>Dmitry A. Kazakov
>http://www.dmitry-kazakov.de




  parent reply	other threads:[~2009-01-01 20:41 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-01-01 11:16 Ada.Directories problems, a summary Dmitry A. Kazakov
2009-01-01 13:47 ` Ivan Levashew
2009-01-01 14:15   ` Dmitry A. Kazakov
2009-01-02 14:22     ` Ivan Levashew
2009-01-02 14:49       ` Dmitry A. Kazakov
2009-01-02 22:33         ` Colin Paul Gloster
2009-01-03  9:08           ` Dmitry A. Kazakov
2009-01-05 10:01       ` Jean-Pierre Rosen
2009-01-02 22:57     ` Randy Brukardt
2009-01-03  9:39       ` Dmitry A. Kazakov
2009-01-06  1:23         ` Randy Brukardt
2009-01-06  1:23         ` Randy Brukardt
2009-01-06 10:41           ` Dmitry A. Kazakov
2009-01-01 13:56 ` Dmitry A. Kazakov
2009-01-01 14:05 ` Colin Paul Gloster
2009-01-01 14:29   ` Dmitry A. Kazakov
2009-01-01 20:41 ` anon [this message]
2009-01-02 11:22   ` Colin Paul Gloster
2009-01-02 10:22 ` Georg Bauhaus
2009-01-02 11:09   ` Dmitry A. Kazakov
replies disabled

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox