home *** CD-ROM | disk | FTP | other *** search
/ Really Useful CD 1 / ReallyUsefulCD1.iso / extras / progutils / baslib / baslibdoc / fsyslib next >
Encoding:
Text File  |  1989-03-15  |  4.4 KB  |  164 lines

  1. Routine   : FNdir_read(name$(),dirname$, 
  2.             filename$,blk%) 
  3. Library   : FSysLib
  4. Purpose   : Reads the specified directory 
  5.             entries into a string array. 
  6. Source    : User
  7. Author    : Paul Hobbs
  8. Parameters:
  9.    name$()  = the string array to receive 
  10.               the entries
  11.    dirname$ = the directory name to read
  12.    filename$= the file name to read
  13.    blk%     = pointer to a 256 byte memory   
  14.               block
  15. Dependant Routines:
  16.    FNmem_to_string(block%,offset%,term%)
  17. Global Variables:
  18.    None 
  19. Notes: 
  20.    Routine returns the number of entries 
  21.    read from the directory. Both the 
  22.    directory name and the filename may be 
  23.    wildcarded, i.e. a filename of "W*" would 
  24.    only read the entries begining with W. A 
  25.    null directory name means 'read the 
  26.    current directory'.
  27. Routine   : FNcatinfo_read(object$) 
  28. Library   : FSysLib
  29. Purpose   : Reads the catalogue info 
  30.             (attributes,load & exec 
  31.             addresses and length) for a 
  32.             given object. 
  33. Source    : User
  34. Author    : Paul Hobbs
  35. Parameters:
  36.    object$  = the object to obtain 
  37.               information on (may be 
  38.               wildcarded)
  39. Dependant Routines:
  40.    FNpad_leading(string$,chars$,nr%)
  41. Global Variables:
  42.    None 
  43. Notes: 
  44.    The routine returns a string which can be 
  45.    used to determine whether an object 
  46.    exists, and if it does whether it is a 
  47.    file or a directory. The string is in the 
  48.    following format:
  49.  
  50.    03 bytes a combination of LWRD 
  51.             (attributes)
  52.    01 byte  space
  53.    08 bytes load address (hex)
  54.    01 byte  space
  55.    08 bytes exec address (hex)
  56.    01 byte  space
  57.    08 bytes length (hex)
  58.  
  59.    "Not Found" is the string returned if the 
  60.    object does not exist.
  61. Routine   : FNfile_loadaddr(object$) 
  62. Library   : FSysLib
  63. Purpose   : Reads the specified file load address
  64. Source    : User
  65. Author    : Paul Hobbs
  66. Parameters:
  67.    object$  = the object to obtain the load 
  68.               address for. 
  69. Dependant Routines:
  70.    None
  71. Global Variables:
  72.    None 
  73. Notes: 
  74.    The routine returns a the value of the load 
  75.    address in base 10. This may be displayed in 
  76.    hex with 'PRINT ~(FNfile_loadaddr())' for 
  77.    example. Check that the file exists first as 
  78.    otherwise an error will occur.
  79. Routine   : FNfile_execaddr(object$) 
  80. Library   : FSysLib
  81. Purpose   : Reads the specified file exec address
  82. Source    : User
  83. Author    : Paul Hobbs
  84. Parameters:
  85.    object$  = the object to obtain the exec 
  86.               address for. 
  87. Dependant Routines:
  88.    None
  89. Global Variables:
  90.    None 
  91. Notes: 
  92.    The routine returns a the value of the exec 
  93.    address in base 10. This may be displayed in 
  94.    hex with 'PRINT ~(FNfile_execaddr())' for 
  95.    example. Check that the file exists first as 
  96.    otherwise an error will occur.
  97. Routine   : FNfile_length(object$) 
  98. Library   : FSysLib
  99. Purpose   : Reads the specified file length
  100. Source    : User
  101. Author    : Paul Hobbs
  102. Parameters:
  103.    object$  = the object to obtain the length of
  104. Dependant Routines:
  105.    None
  106. Global Variables:
  107.    None 
  108. Notes: 
  109.    The routine returns a the length of the 
  110.    specified object in base 10. This may be 
  111.    displayed in hex with 'PRINT 
  112.    ~(FNfile_length())' for example. Check that the 
  113.    file exists first as otherwise an error will 
  114.    occur.
  115. Routine   : FNfile_exists(object$) 
  116. Library   : FSysLib
  117. Purpose   : Checks that the specified object 
  118.             exists
  119. Source    : User
  120. Author    : Paul Hobbs
  121. Parameters:
  122.    object$  = the object to check
  123. Dependant Routines:
  124.    FNcatinfo_read(object$)
  125.    FNpad_leading(string$,chars$,nr%)
  126. Global Variables:
  127.    None 
  128. Notes: 
  129.    The routine returns TRUE if the object exists, 
  130.    FALSE if it does not.
  131. Routine   : FNfile_type(object$) 
  132. Library   : FSysLib
  133. Purpose   : Returns the file type of the specified 
  134.             file
  135. Source    : Archive November 1988 Page 40
  136. Author    : Clive Payne
  137. Parameters:
  138.    object$  = the object to retrieve the file type 
  139.               for
  140. Dependant Routines:
  141.    None
  142. Global Variables:
  143.    None 
  144. Notes: 
  145.    An error will occur if the file does not exist, 
  146.    so check first with FNfile_exists().   
  147. Routine   : FNdemo_dir_read 
  148. Library   : FSysLib
  149. Purpose   : A demo of reading information from a 
  150.             specified directory
  151. Source    : User
  152. Author    : Paul Hobbs
  153. Parameters:
  154.    None
  155. Dependant Routines:
  156.    FNcatinfo_read()
  157.    FNpad_leading()   
  158. Global Variables:
  159.    None 
  160. Notes: 
  161.    The root directory is read and displayed (file 
  162.    names and load & exec addresses etc.)
  163.  
  164.