home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Professional / OS2PRO194.ISO / os2 / prgramer / pascal2c / fs.imp < prev    next >
Text File  |  1992-08-03  |  5KB  |  119 lines

  1.  
  2.  
  3. {IncludeFrom=fs <fs.h>}
  4.  
  5.  
  6. {*VarStrings=0} {*VarFiles=0} {*ExportSymbol=fs_%s} {*Export_Symbol=%s}
  7.  
  8.  
  9. module fs;    {file support} 
  10.  
  11. import sysgloba, asm, misc;
  12.  
  13. export
  14.  
  15. type 
  16.      closetype = (cnormal, lock, purge, ccrunch); 
  17.      faccess = (readonly,writeonly,readwrite,writeappend,overwrite);
  18.      vptr = record case integer of
  19.               0: (j: integer);
  20.               1: (i: ^shortint); 
  21.               2: (s: ^string80);
  22.               end;
  23.            
  24.  
  25. procedure fstripname(s : fid; var pvname,ppath,pfname : string);
  26. procedure fixname(var title: string; kind: filekind); 
  27. procedure zapspaces(var s: string); 
  28. function suffix(var ftitle: string): filekind; 
  29. function scantitle (fname: fid; var fvid: vid; var ftitle: fid; 
  30.                             var fsegs: integer; var fkind: filekind): boolean; 
  31. function findvolume (var fvid: vid; verify: boolean): unitnum; 
  32. procedure doprefix(var dirname:fid; var kvid:vid; var kunit:integer; 
  33.                                                              findunit:boolean);
  34.  
  35. {WarnNames=1}
  36. procedure finitb (var f: fib; window: windowp; recbytes: integer); 
  37. procedure fhpopen(var f: fib; typ: faccess; var title, option: string255);
  38. procedure fhpreset(var f: fib; typ: faccess);
  39. procedure fcloseit(var f: fib; stype: string255);
  40. procedure fclose (var f: fib; ftype: closetype); 
  41. procedure fmaketype(anyvar f:fib; var title, option, typestring: string); 
  42. procedure foverfile(anyvar f:fib; var title, option, typestring: string); 
  43. procedure fanonfile(anyvar f:fib; var name:string; kind:filekind;size:integer);
  44.  
  45. procedure fseek(var f: fib; position: integer); 
  46. function fposition(var f: fib): integer;
  47. function fmaxpos(var f: fib): integer;
  48.  
  49. function fbufferref(var f: fib): windowp;
  50. procedure fget (var f: fib); 
  51. procedure fput (var f: fib); 
  52. function feof (var f: fib): boolean; 
  53. function feoln (var f: fib): boolean; 
  54. procedure fwriteln (var f: fib); 
  55.  
  56. procedure fread(anyvar f: fib; anyvar buf: window); 
  57. procedure fwrite(anyvar f: fib;  anyvar buf: window); 
  58.  
  59. {WarnNames}
  60. procedure freadbytes(anyvar f: fib; anyvar buf: window; size: integer); 
  61. procedure fwritebytes(anyvar f: fib;  anyvar buf: window; size: integer); 
  62. {*WarnNames=1}
  63.  
  64. function fblockio (var f: fib; var buf: window;
  65.                            nblocks,rblock: integer; doread: boolean): integer; 
  66.  
  67.  
  68. procedure killchar (anyvar f: fib; var sinx: integer); 
  69.  
  70. procedure fpage (var t: text); 
  71. procedure foverprint(var t: text); 
  72. procedure fgotoxy(anyvar f: fib;      x, y:  integer); 
  73. procedure fgetxy (anyvar f: fib;  var x, y:  integer); 
  74.  
  75. procedure freadln (var t:text); 
  76. procedure fwritechar (var t: text; ch: char; rleng: shortint); 
  77. procedure freadchar (var t:text; var ch: char);
  78. procedure freadword (var t:text; var i: shortint);
  79. procedure freadint (var t:text; var i: integer); 
  80. procedure fwriteword (var t:text;i,rleng: shortint); 
  81. procedure fwriteint (var t:text;i: integer; rleng: shortint); 
  82. procedure fwritestr (var t:text;anyvar s: string80; rleng: shortint); 
  83. procedure freadstr (var t:text; var s: string);
  84. procedure fwritepaoc (var t: text; var a: window; aleng,rleng: shortint); 
  85. procedure freadpaoc (var t: text; var a: window; aleng: shortint);
  86. procedure freadenum (var t: text; var i: shortint; p: vptr);
  87. procedure fwriteenum(var t: text; i: shortint; rleng: shortint; p: vptr);
  88. procedure freadbool (var t: text; var b: boolean);
  89. procedure fwritebool(var t: text; b: boolean; rleng: shortint);
  90.  
  91.  
  92. procedure freadstrchar (var s: string255;var p2: integer; var ch: char);
  93. procedure fwritestrchar (var s: string;
  94.                                   var p2: integer; ch: char; rleng: shortint); 
  95. procedure freadstrword (var s: string255;var p2: integer; var i: shortint);
  96. {PROCEDURE FREADSTRINT (VAR S: STRING255;VAR P2,I: INTEGER);}
  97. procedure fwritestrword (var s: string;var p2: integer; i,rleng: shortint); 
  98. {PROCEDURE FWRITESTRINT(VAR T: STRING;
  99.                                VAR P2: INTEGER; I: INTEGER; RLENG: SHORTINT); }
  100. procedure freadstrstr (var t: string255;var p2: integer; var s: string);
  101. procedure fwritestrstr (var s: string; var p2: integer;
  102.                                         anyvar t: string255; rleng: shortint); 
  103. procedure fwritestrpaoc (var s: string; var p2: integer;
  104.                                         var a: window; aleng,rleng: shortint); 
  105. procedure freadstrpaoc (var s: string255; var p2: integer;
  106.                                               var a: window; aleng: shortint);
  107. procedure freadstrenum (var s: string255;
  108.                                     var p2: integer; var i: shortint; p: vptr);
  109. procedure fwritestrenum(var s: string;
  110.                                   var p2: integer; i,rleng: shortint; p: vptr);
  111. procedure freadstrbool (var s: string255;var p2: integer; var b: boolean);
  112. procedure fwritestrbool(var s: string;
  113.                                  var p2: integer; b: boolean; rleng: shortint);
  114.  
  115.  
  116. end.
  117.  
  118.  
  119.