comp.lang.ada
 help / color / mirror / Atom feed
* How to be sure of if a file exist?
@ 1996-07-05  0:00 Markus Wahl
  1996-07-07  0:00 ` Robert Dewar
                   ` (2 more replies)
  0 siblings, 3 replies; 5+ messages in thread
From: Markus Wahl @ 1996-07-05  0:00 UTC (permalink / raw)




How can I make my program find out which files that exist in a certain
directory?

/Markus

"I have no hard currency, but if I did could I buy you a drink?" - Fidel Castro





^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: How to be sure of if a file exist?
  1996-07-05  0:00 How to be sure of if a file exist? Markus Wahl
@ 1996-07-07  0:00 ` Robert Dewar
  1996-07-08  0:00 ` Tarjei Jensen
  1996-07-08  0:00 ` Walter B. Hollman Sr.
  2 siblings, 0 replies; 5+ messages in thread
From: Robert Dewar @ 1996-07-07  0:00 UTC (permalink / raw)



Markus said

"How can I make my program find out which files that exist in a certain
directory?"

There is no implementation independent way of doing this (indeed even the
idea of a directory is somewhat implementation dependent).

No doubt the operating system that provides the directories also provides
some routines that answer your question. Find out what these routines are
and call them. To call them from Ada, use pragma Import with the appropriate
convention name. For example, if you find some Fortran routines that do
what you want, call them using pragma Import (Fortran, ...)





^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: How to be sure of if a file exist?
  1996-07-05  0:00 How to be sure of if a file exist? Markus Wahl
  1996-07-07  0:00 ` Robert Dewar
  1996-07-08  0:00 ` Tarjei Jensen
@ 1996-07-08  0:00 ` Walter B. Hollman Sr.
  2 siblings, 0 replies; 5+ messages in thread
From: Walter B. Hollman Sr. @ 1996-07-08  0:00 UTC (permalink / raw)



On Jul 05, 1996 17:26:33 in article <How to be sure of if a file exist?>,
'Markus Wahl <d95wahl@dtek.chalmers.se>' wrote: 
 
 
> 
>How can I make my program find out which files that exist in a certain 
>directory? 
> 
>/Markus 
> 
>"I have no hard currency, but if I did could I buy you a drink?" - Fidel  
>Castro 
> 
--Write a package to test for the presence of the file. 
Walter B. Hollman Sr 
 
 
 
 
 
 
 





^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: How to be sure of if a file exist?
  1996-07-05  0:00 How to be sure of if a file exist? Markus Wahl
  1996-07-07  0:00 ` Robert Dewar
@ 1996-07-08  0:00 ` Tarjei Jensen
  1996-07-09  0:00   ` Larry Kilgallen
  1996-07-08  0:00 ` Walter B. Hollman Sr.
  2 siblings, 1 reply; 5+ messages in thread
From: Tarjei Jensen @ 1996-07-08  0:00 UTC (permalink / raw)



Try importing the Posix routines for directory access if you are on a Unix or
OS/2 (emx) machine. Otherwise you will have to write your own.


Greetings,

 
--
// Tarjei T. Jensen 
//    tarjeij@ulrik.uio.no || fax +47 51664292  || voice +47 51 85 87 39
//   Support you local rescue centre: GET LOST!
// Working, but not speaking for the Norwegian Hydrographic Service.




^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: How to be sure of if a file exist?
  1996-07-08  0:00 ` Tarjei Jensen
@ 1996-07-09  0:00   ` Larry Kilgallen
  0 siblings, 0 replies; 5+ messages in thread
From: Larry Kilgallen @ 1996-07-09  0:00 UTC (permalink / raw)



The rules for what constitutes a valid file name will vary between
various operating systems.  In most cases file names which lack an
embedded device and/or directory specification will go to some "current"
area, but sometimes that area will not exist or will not be writable
by the user.

One cannot write a program which uses files without some knowledge of
the operating system environment(s).

Larry Kilgallen




^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~1996-07-09  0:00 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
1996-07-05  0:00 How to be sure of if a file exist? Markus Wahl
1996-07-07  0:00 ` Robert Dewar
1996-07-08  0:00 ` Tarjei Jensen
1996-07-09  0:00   ` Larry Kilgallen
1996-07-08  0:00 ` Walter B. Hollman Sr.

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