Back to Imagemagick

Magick++: BlobRef.h Source File

www/api/Magick++/BlobRef_8h_source.html

7.1.2-215.0 KB
Original Source

| Magick++ 7.1.0 |

BlobRef.h

Go to the documentation of this file.

1 // This may look like C code, but it is really -*- C++ -*-

2 //

3 // Copyright Bob Friesenhahn, 1999, 2000, 2001, 2002

4 //

5 // Copyright @ 2014 ImageMagick Studio LLC, a non-profit organization

6 // dedicated to making software imaging solutions freely available.

7 //

8 // Blob reference class

9 //

10 // This is an internal implementation class that should not be

11 // accessed by users.

12 //

13

14 #if !defined(Magick_Blob_header)

15 #define Magick_Blob_header

16

17 #include "Magick++/Include.h"

18 #include "Magick++/Thread.h"

19 #include "Magick++/Blob.h"

20

21 namespace Magick

22 {

23class BlobRef

24 {

25public:

26

27// Construct with data, making private copy of data

28BlobRef(const void* data_,const size_t length_);

29

30// Destructor (actually destroys data)

31~BlobRef(void);

32

33// Decreases reference count and return the new count

34size_t decrease();

35

36// Increases reference count

37void increase();

38

39Blob::Allocator allocator; // Memory allocation system in use

40size_tlength; // Blob length

41void* data; // Blob data

42

43private:

44// Copy constructor and assignment are not supported

45BlobRef(const BlobRef&);

46BlobRef& operator=(const BlobRef&);

47

48MutexLock _mutexLock; // Mutex lock

49size_t _refCount; // Reference count

50 };

51

52 } // namespace Magick

53

54 #endif // Magick_Blob_header

Magick::BlobRef::BlobRef

BlobRef(const void *data_, const size_t length_)

Definition: BlobRef.cpp:21

Magick::BlobRef::allocator

Blob::Allocator allocator

Definition: BlobRef.h:39

Magick::BlobRef::data

void * data

Definition: BlobRef.h:41

Magick::MutexLock

Definition: Thread.h:29

Thread.h

Magick::BlobRef::increase

void increase()

Definition: BlobRef.cpp:64

Magick::BlobRef::decrease

size_t decrease()

Definition: BlobRef.cpp:46

Include.h

Magick::BlobRef::length

size_t length

Definition: BlobRef.h:40

Magick::BlobRef

Definition: BlobRef.h:23

Magick::Blob::Allocator

Allocator

Definition: Blob.h:26

Magick

Definition: Blob.h:17

Blob.h

Magick::BlobRef::~BlobRef

~BlobRef(void)

Definition: BlobRef.cpp:35