0024512: clang++ compiler complains about extra semicolon
[occt.git] / src / NCollection / NCollection_HeapAllocator.hxx
CommitLineData
b311480e 1// Created on: 2009-12-30
2// Created by: Alexander GRIGORIEV
973c2be1 3// Copyright (c) 2009-2014 OPEN CASCADE SAS
b311480e 4//
973c2be1 5// This file is part of Open CASCADE Technology software library.
b311480e 6//
973c2be1 7// This library is free software; you can redistribute it and / or modify it
8// under the terms of the GNU Lesser General Public version 2.1 as published
9// by the Free Software Foundation, with special exception defined in the file
10// OCCT_LGPL_EXCEPTION.txt. Consult the file LICENSE_LGPL_21.txt included in OCCT
11// distribution for complete text of the license and disclaimer of any warranty.
b311480e 12//
973c2be1 13// Alternatively, this file may be used under the terms of Open CASCADE
14// commercial license or contractual agreement.
7fd59977 15
16#ifndef NCollection_HeapAllocator_HeaderFile
17#define NCollection_HeapAllocator_HeaderFile
18
19#include <NCollection_BaseAllocator.hxx>
20
21class Handle_NCollection_HeapAllocator;
22
23/**
24 * Allocator that uses the global dynamic heap (malloc / free).
25 */
26
27class NCollection_HeapAllocator : public NCollection_BaseAllocator
28{
29 public:
30 // ---------- PUBLIC METHODS ----------
31 Standard_EXPORT virtual void* Allocate (const Standard_Size theSize);
32 Standard_EXPORT virtual void Free (void * anAddress);
33
34 Standard_EXPORT static const Handle_NCollection_HeapAllocator&
35 GlobalHeapAllocator();
36
37 protected:
38 //! Constructor - prohibited
5640d653 39 NCollection_HeapAllocator(void) {}
7fd59977 40
41 private:
42 //! Copy constructor - prohibited
43 NCollection_HeapAllocator(const NCollection_HeapAllocator&);
44
45 public:
46// Declaration of CASCADE RTTI
47DEFINE_STANDARD_RTTI (NCollection_HeapAllocator)
48};
49
50// Definition of HANDLE object using Standard_DefineHandle.hxx
51DEFINE_STANDARD_HANDLE (NCollection_HeapAllocator, NCollection_BaseAllocator)
52
53#endif