home *** CD-ROM | disk | FTP | other *** search
/ Fresh Fish 8 / FreshFishVol8-CD1.bin / gnu / os-include / dos / exall.h < prev    next >
C/C++ Source or Header  |  1993-10-15  |  2KB  |  78 lines

  1. #ifndef DOS_EXALL_H
  2. #define DOS_EXALL_H
  3. /*
  4. **
  5. **    $VER: exall.h 36.6 (5.4.92)
  6. **    Includes Release 40.15
  7. **
  8. **    include file for ExAll() data structures
  9. **
  10. **    (C) Copyright 1989-1993 Commodore-Amiga, Inc.
  11. **        All Rights Reserved
  12. **
  13. */
  14.  
  15. #ifndef EXEC_TYPES_H
  16. #include "exec/types.h"
  17. #endif
  18.  
  19. #ifndef UTILITY_HOOKS_H
  20. #include "utility/hooks.h"
  21. #endif
  22.  
  23. /* NOTE: V37 dos.library, when doing ExAll() emulation, and V37 filesystems  */
  24. /* will return an error if passed ED_OWNER.  If you get ERROR_BAD_NUMBER,    */
  25. /* retry with ED_COMMENT to get everything but owner info.  All filesystems  */
  26. /* supporting ExAll() must support through ED_COMMENT, and must check Type   */
  27. /* and return ERROR_BAD_NUMBER if they don't support the type.             */
  28.  
  29. /* values that can be passed for what data you want from ExAll() */
  30. /* each higher value includes those below it (numerically)     */
  31. /* you MUST chose one of these values */
  32. #define    ED_NAME        1
  33. #define    ED_TYPE        2
  34. #define ED_SIZE        3
  35. #define ED_PROTECTION    4
  36. #define ED_DATE        5
  37. #define ED_COMMENT    6
  38. #define ED_OWNER    7
  39.  
  40. /*
  41.  *   Structure in which exall results are returned in.    Note that only the
  42.  *   fields asked for will exist!
  43.  */
  44.  
  45. struct ExAllData {
  46.     struct ExAllData *ed_Next;
  47.     UBYTE  *ed_Name;
  48.     LONG    ed_Type;
  49.     ULONG    ed_Size;
  50.     ULONG    ed_Prot;
  51.     ULONG    ed_Days;
  52.     ULONG    ed_Mins;
  53.     ULONG    ed_Ticks;
  54.     UBYTE  *ed_Comment;    /* strings will be after last used field */
  55.     UWORD    ed_OwnerUID;    /* new for V39 */
  56.     UWORD    ed_OwnerGID;
  57. };
  58.  
  59. /*
  60.  *   Control structure passed to ExAll.  Unused fields MUST be initialized to
  61.  *   0, expecially eac_LastKey.
  62.  *
  63.  *   eac_MatchFunc is a hook (see utility.library documentation for usage)
  64.  *   It should return true if the entry is to returned, false if it is to be
  65.  *   ignored.
  66.  *
  67.  *   This structure MUST be allocated by AllocDosObject()!
  68.  */
  69.  
  70. struct ExAllControl {
  71.     ULONG    eac_Entries;     /* number of entries returned in buffer      */
  72.     ULONG    eac_LastKey;     /* Don't touch inbetween linked ExAll calls! */
  73.     UBYTE  *eac_MatchString; /* wildcard string for pattern match or NULL */
  74.     struct Hook *eac_MatchFunc; /* optional private wildcard function     */
  75. };
  76.  
  77. #endif /* DOS_EXALL_H */
  78.