home *** CD-ROM | disk | FTP | other *** search
/ Power-Programmierung / CD2.mdf / c / library / mslang / vm / h / vmemory.h < prev    next >
Encoding:
C/C++ Source or Header  |  1993-12-15  |  1.6 KB  |  62 lines

  1. /***
  2. * vmemory.h - Virtual Memory (VM) Management Routines
  3. *
  4. *       Copyright (c) 1989-1992, Microsoft Corporation.  All rights reserved.
  5. *
  6. *Purpose:
  7. *       This include file provides prototypes and definitions for
  8. *       the virtual memory management routines.
  9. *
  10. *******************************************************************************/
  11.  
  12. #ifndef _INC_VMEMORY
  13.  
  14. #if (_MSC_VER <= 600)
  15. #define __far       _far
  16. #define __pascal    _pascal
  17. #endif
  18.  
  19. /* virtual memory handle type */
  20. typedef unsigned long _vmhnd_t;
  21.  
  22. /* null handle value */
  23. #define _VM_NULL        ((_vmhnd_t) 0)
  24.  
  25. /* use all available DOS memory for virtual heap */
  26. #define _VM_ALLDOS      0
  27.  
  28. /* swap areas */
  29. #define _VM_EMS         1
  30. #define _VM_XMS         2
  31. #define _VM_DISK        4
  32. #define _VM_ALLSWAP     (_VM_EMS | _VM_XMS | _VM_DISK)
  33.  
  34. /* clean/dirty flags */
  35. #define _VM_CLEAN       0
  36. #define _VM_DIRTY       1
  37.  
  38. /* function prototypes */
  39.  
  40. #ifdef __cplusplus
  41. extern "C" {
  42. #endif
  43.  
  44. void __far __pascal _vfree(_vmhnd_t);
  45. int __far __pascal _vheapinit(unsigned int, unsigned int, unsigned int);
  46. void __far __pascal _vheapterm(void);
  47. void __far * __far __pascal _vload(_vmhnd_t, int);
  48. void __far * __far __pascal _vlock(_vmhnd_t);
  49. unsigned int __far __pascal _vlockcnt(_vmhnd_t);
  50. unsigned long __far __pascal _vmsize(_vmhnd_t);
  51. void __far __pascal _vunlock(_vmhnd_t, int);
  52.  
  53. _vmhnd_t __far __pascal _vmalloc(unsigned long);
  54. _vmhnd_t __far __pascal _vrealloc(_vmhnd_t , unsigned long);
  55.  
  56. #ifdef __cplusplus
  57. }
  58. #endif
  59.  
  60. #define _INC_VMEMORY
  61. #endif /* _INC_VMEMORY */
  62.