The package Standard provides global memory allocator and other basic services used by other OCCT components.  
 More...
#include <Standard.hxx>
The package Standard provides global memory allocator and other basic services used by other OCCT components. 
◆ Allocate()
Allocates memory blocks aSize - bytes to allocate. 
 
 
◆ AllocateAligned()
Allocates aligned memory blocks. Should be used with CPU instructions which require specific alignment. For example: SSE requires 16 bytes, AVX requires 32 bytes. 
- Parameters
- 
  
    | theSize | bytes to allocate |  | theAlign | alignment in bytes |  
 
 
 
◆ Free() [1/2]
Deallocates memory blocks. 
- Parameters
- 
  
    | thePtr | - previously allocated memory block to be freed |  
 
 
 
◆ Free() [2/2]
template<typename T > 
  
  | 
        
          | static void Standard::Free | ( | T *& | thePtr | ) |  |  | inlinestatic | 
 
Template version of function Free(), nullifies the argument pointer. 
- Parameters
- 
  
    | thePtr | - previously allocated memory block to be freed |  
 
 
 
◆ FreeAligned() [1/2]
Deallocates memory blocks. 
- Parameters
- 
  
  
 
 
◆ FreeAligned() [2/2]
template<typename T > 
  
  | 
        
          | static void Standard::FreeAligned | ( | T *& | thePtrAligned | ) |  |  | inlinestatic | 
 
Template version of function FreeAligned(), nullifies the argument pointer. 
- Parameters
- 
  
  
 
 
◆ Purge()
Deallocates the storage retained on the free list and clears the list. Returns non-zero if some memory has been actually freed. 
 
 
◆ Reallocate()
Reallocates memory blocks aStorage - previously allocated memory block aNewSize - new size in bytes. 
 
 
◆ StackTrace()
  
  | 
        
          | static Standard_Boolean Standard::StackTrace | ( | char * | theBuffer, |  
          |  |  | const int | theBufferSize, |  
          |  |  | const int | theNbTraces, |  
          |  |  | void * | theContext = NULL, |  
          |  |  | const int | theNbTopSkip = 0 |  
          |  | ) |  |  |  | static | 
 
Appends backtrace to a message buffer. Stack information might be incomplete in case of stripped binaries. Implementation details: 
- Not implemented for Android, iOS, QNX and UWP platforms.
- On non-Windows platform, this function is a wrapper to backtrace() system call.
- On Windows (Win32) platform, the function loads DbgHelp.dll dynamically, and no stack will be provided if this or companion libraries (SymSrv.dll, SrcSrv.dll, etc.) will not be found; .pdb symbols should be provided on Windows platform to retrieve a meaningful stack; only x86_64 CPU architecture is currently implemented. - Parameters
- 
  
    | theBuffer | [in] [out] message buffer to extend |  | theBufferSize | [in] message buffer size |  | theNbTraces | [in] maximum number of stack traces |  | theContext | [in] optional platform-dependent frame context; in case of DbgHelp (Windows) should be a pointer to CONTEXT |  | theNbTopSkip | [in] number of traces on top of the stack to skip |  
 
 - Returns
- TRUE on success 
 
 
 
The documentation for this class was generated from the following file: