home *** CD-ROM | disk | FTP | other *** search
/ OpenStep 4.2 / Openstep-4.2-Intel-Developer.iso / NextLibrary / Frameworks / Foundation.framework / Versions / B / Headers / NSZone.h < prev   
Encoding:
Text File  |  1996-10-25  |  1.4 KB  |  32 lines

  1. /*    NSZone.h
  2.     Allocation of large regions
  3.     Copyright 1994-1996, NeXT Software, Inc.  All rights reserved.
  4. */
  5.  
  6. #import <Foundation/NSObjCRuntime.h>
  7.  
  8. @class NSString;
  9.  
  10. typedef struct _NSZone NSZone;
  11.  
  12. FOUNDATION_EXPORT NSZone *NSDefaultMallocZone(void);
  13. FOUNDATION_EXPORT NSZone *NSCreateZone(unsigned startSize, unsigned granularity, BOOL canFree);
  14. FOUNDATION_EXPORT void NSRecycleZone(NSZone *zone);
  15. FOUNDATION_EXPORT void NSSetZoneName(NSZone *zone, NSString *name);
  16. FOUNDATION_EXPORT NSString *NSZoneName(NSZone *zone);
  17. FOUNDATION_EXPORT NSZone *NSZoneFromPointer(void *ptr);
  18.  
  19. FOUNDATION_EXPORT void *NSZoneMalloc(NSZone *zone, unsigned size);
  20. FOUNDATION_EXPORT void *NSZoneCalloc(NSZone *zone, unsigned numElems, unsigned byteSize);
  21. FOUNDATION_EXPORT void *NSZoneRealloc(NSZone *zone, void *ptr, unsigned size);
  22. FOUNDATION_EXPORT void NSZoneFree(NSZone *zone, void *ptr);
  23.  
  24. FOUNDATION_EXPORT unsigned NSPageSize(void);
  25. FOUNDATION_EXPORT unsigned NSLogPageSize(void);
  26. FOUNDATION_EXPORT unsigned NSRoundUpToMultipleOfPageSize(unsigned bytes);
  27. FOUNDATION_EXPORT unsigned NSRoundDownToMultipleOfPageSize(unsigned bytes);
  28. FOUNDATION_EXPORT void *NSAllocateMemoryPages(unsigned bytes);
  29. FOUNDATION_EXPORT void NSDeallocateMemoryPages(void *ptr, unsigned bytes);
  30. FOUNDATION_EXPORT void NSCopyMemoryPages(const void *source, void *dest, unsigned bytes);
  31. FOUNDATION_EXPORT unsigned NSRealMemoryAvailable(void);
  32.