Magick++  6.9.3
ResourceLimits.h
Go to the documentation of this file.
1 // This may look like C code, but it is really -*- C++ -*-
2 //
3 // Copyright Dirk Lemstra 2014
4 //
5 // Definition of resource limits.
6 //
7 
8 #if !defined(Magick_ResourceLimits_header)
9 #define Magick_ResourceLimits_header
10 
11 #include "Magick++/Include.h"
12 
13 namespace Magick
14 {
16  {
17  public:
18 
19  // Pixel cache limit in bytes. Requests for memory above this limit
20  // are automagically allocated on disk.
21  static void area(const MagickSizeType limit_);
22  static MagickSizeType area(void);
23 
24  // Pixel cache limit in bytes. Requests for memory above this limit
25  // will fail.
26  static void disk(const MagickSizeType limit_);
27  static MagickSizeType disk(void);
28 
29  // Pixel cache limit in bytes. Once this memory limit is exceeded,
30  // all subsequent pixels cache operations are to/from disk.
31  static void map(const MagickSizeType limit_);
32  static MagickSizeType map(void);
33 
34  // Pixel cache limit in bytes. Once this memory limit is exceeded,
35  // all subsequent pixels cache operations are to/from disk or to/from
36  // memory mapped files.
37  static void memory(const MagickSizeType limit_);
38  static MagickSizeType memory(void);
39 
40  // Limits the number of threads used in multithreaded operations.
41  static void thread(const MagickSizeType limit_);
42  static MagickSizeType thread(void);
43 
44  private:
45  ResourceLimits(void);
46 
47  }; // class ResourceLimits
48 
49 } // Magick namespace
50 
51 #endif // Magick_ResourceLimits_header
#define MagickPPExport
Definition: Include.h:255
Definition: Blob.h:15