home *** CD-ROM | disk | FTP | other *** search
/ Liren Large Software Subsidy 7 / 07.iso / c / c083 / 14.ddi / GENINC.PAK / DIR.H < prev    next >
Encoding:
C/C++ Source or Header  |  1993-12-02  |  2.9 KB  |  110 lines

  1. /*  dir.h
  2.  
  3.     Defines structures, macros, and functions for dealing with
  4.     directories and pathnames.
  5.  
  6. */
  7.  
  8. /*
  9.  *      C/C++ Run Time Library - Version 6.0
  10.  *
  11.  *      Copyright (c) 1987, 1993 by Borland International
  12.  *      All Rights Reserved.
  13.  *
  14.  */
  15.  
  16. #if !defined(__DIR_H)
  17. #define __DIR_H
  18.  
  19. #if !defined(___DEFS_H)
  20. #include <_defs.h>
  21. #endif
  22.  
  23. #define WILDCARDS 0x01
  24. #define EXTENSION 0x02
  25. #define FILENAME  0x04
  26. #define DIRECTORY 0x08
  27. #define DRIVE     0x10
  28.  
  29. #define MAXDRIVE  3
  30.  
  31. #if !defined(__FLAT__)
  32.  
  33. #ifndef _FFBLK_DEF
  34. #define _FFBLK_DEF
  35. struct  ffblk   {
  36.     char        ff_reserved[21];
  37.     char        ff_attrib;
  38.     unsigned    ff_ftime;
  39.     unsigned    ff_fdate;
  40.     long        ff_fsize;
  41.     char        ff_name[13];
  42. };
  43. #endif
  44.  
  45. #define MAXPATH   80
  46. #define MAXDIR    66
  47. #define MAXFILE   9
  48. #define MAXEXT    5
  49.  
  50. #else  /* defined __FLAT__ */
  51.  
  52. #pragma option -a-
  53.  
  54. #ifndef _FFBLK_DEF
  55. #define _FFBLK_DEF
  56. struct  ffblk   {
  57.     long            ff_reserved;
  58.     long            ff_fsize;
  59.     unsigned long   ff_attrib;
  60.     unsigned short  ff_ftime;
  61.     unsigned short  ff_fdate;
  62.     char            ff_name[256];
  63. };
  64. #endif
  65.  
  66. #define MAXPATH   260
  67. #define MAXDIR    256
  68. #define MAXFILE   256
  69. #define MAXEXT    256
  70.  
  71. #pragma option -a.  /* restore default packing */
  72.  
  73. #endif  /* __FLAT__  */
  74.  
  75. #ifdef __cplusplus
  76. extern "C" {
  77. #endif
  78.  
  79. int         _RTLENTRYF _EXPFUNC32   chdir( const char _FAR *__path );
  80. int         _RTLENTRYF _EXPFUNC     findfirst( const char _FAR *__path,
  81.                                     struct ffblk _FAR *__ffblk,
  82.                                     int __attrib );
  83. int         _RTLENTRYF _EXPFUNC     findnext( struct ffblk _FAR *__ffblk );
  84. void        _RTLENTRYF _EXPFUNC     fnmerge( char _FAR *__path,
  85.                                     const char _FAR *__drive,
  86.                                     const char _FAR *__dir,
  87.                                     const char _FAR *__name,
  88.                                     const char _FAR *__ext );
  89. int         _RTLENTRYF _EXPFUNC     fnsplit(const char _FAR *__path,
  90.                                     char _FAR *__drive,
  91.                                     char _FAR *__dir,
  92.                                     char _FAR *__name,
  93.                                     char _FAR *__ext );
  94. int         _RTLENTRY  _EXPFUNC32   getcurdir( int __drive, char _FAR *__directory );
  95. char _FAR * _RTLENTRY  _EXPFUNC     getcwd( char _FAR *__buf, int __buflen );
  96. int         _RTLENTRY  _EXPFUNC32   getdisk( void );
  97. int         _RTLENTRYF _EXPFUNC32   mkdir( const char _FAR *__path );
  98. char _FAR * _RTLENTRYF _EXPFUNC     mktemp( char _FAR *__template );
  99. int         _RTLENTRY  _EXPFUNC32   rmdir( const char _FAR *__path );
  100. char _FAR * _RTLENTRYF _EXPFUNC32   searchpath( const char _FAR *__file );
  101. int         _RTLENTRY  _EXPFUNC32   setdisk( int __drive );
  102.  
  103. #ifdef __cplusplus
  104. }
  105. #endif
  106.  
  107. #endif  /* __DIR_H */
  108.  
  109.  
  110.