comp.lang.ada
 help / color / mirror / Atom feed
From: Shark8 <onewingedshark@gmail.com>
Subject: Re: Operating System differences and Ada OS independent programming
Date: Wed, 23 Mar 2016 20:36:45 -0700 (PDT)
Date: 2016-03-23T20:36:45-07:00	[thread overview]
Message-ID: <47928e41-a04b-46fb-a5cc-3a3451e0246e@googlegroups.com> (raw)
In-Reply-To: <nctkn9$rjn$1@gioia.aioe.org>

On Wednesday, March 23, 2016 at 2:39:08 AM UTC-6, Dmitry A. Kazakov wrote:
> 
> Ada's abstraction should reflect the most generic file system properties:
> 
> - Acyclic directed graph of names built from Unicode code points;

No, these should be a private type which is 0..Unsigned_32/64 and has the name as a property whose value is a unicode string. There should be a "translate" function which takes a Unicode string and translates it into the filesystem-actual's encoding. -- an identical yet distinct type should exist for directories.

> - Multiple roots (AKA devices);

No, absolutely not.
These should NOT be part of the filesystem; instead there should be a Physical_Drive type and a Virtual_Drive type, where the former denotes a physical drive, and the virtual denotes either a single partition of a physical_drive or multiple physical drives. (VMS has the capibility to view multiple HDs as a single logical drive.)

UNIX caused all sorts of trouble with their misguided "everything's a file" stupidity.

> - Absolute vs. relative path distinction;

Yes.

> - Current directory path generator;

Pretty much unneeded if there's a directory-type:
Type FS_Rider is
  Current : Directory_Type;
  -- Other state information.
end record;

> - Generators for special directory paths (home, my downloads, my 
> documents etc);

These could be a simple map (key -> directory_type), populated as needed by the particular OS/FS.

> - Extension / MIME types;

Why?

> - Version / change / release number;

Definitely.

> - Time stamps (modification, creation etc).

Which should be Ada.Calendar.Time.


  parent reply	other threads:[~2016-03-24  3:36 UTC|newest]

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-03-21 13:18 Operating System differences and Ada OS independent programming ldries46
2016-03-21 15:07 ` gautier_niouzes
2016-03-21 17:24 ` Dennis Lee Bieber
2016-03-21 22:04   ` Randy Brukardt
2016-03-22  8:43     ` Dmitry A. Kazakov
2016-03-22 11:15       ` G.B.
2016-03-22 13:40         ` Dmitry A. Kazakov
2016-03-22 14:36           ` Stefan.Lucks
2016-03-22 15:08           ` G.B.
2016-03-22 19:06             ` Dmitry A. Kazakov
2016-03-23  8:13         ` gautier_niouzes
2016-03-23  8:38           ` Dmitry A. Kazakov
2016-03-23 15:08             ` G.B.
2016-03-24  8:00               ` Dmitry A. Kazakov
2016-03-24 10:41                 ` G.B.
2016-03-24 10:42                   ` G.B.
2016-03-24 12:16                   ` Dmitry A. Kazakov
2016-03-24  3:36             ` Shark8 [this message]
2016-03-24  7:58               ` Dmitry A. Kazakov
2016-03-24 11:42                 ` Dennis Lee Bieber
2016-03-24  1:19 ` rieachus
replies disabled

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