VTK  9.5.20250901
Public Member Functions | List of all members
vtkCocoaAutoreleasePool Class Reference

RAII class to create an NSAutoreleasePool. More...

#include <vtkCocoaAutoreleasePool.h>

Public Member Functions

 vtkCocoaAutoreleasePool ()
 
 ~vtkCocoaAutoreleasePool ()
 
void Release ()
 Release the pool to reclaim the memory.
 

Detailed Description

RAII class to create an NSAutoreleasePool.

Tests:
vtkCocoaAutoreleasePool (Tests)

Definition at line 18 of file vtkCocoaAutoreleasePool.h.

Constructor & Destructor Documentation

◆ vtkCocoaAutoreleasePool()

vtkCocoaAutoreleasePool::vtkCocoaAutoreleasePool ( )

◆ ~vtkCocoaAutoreleasePool()

vtkCocoaAutoreleasePool::~vtkCocoaAutoreleasePool ( )

Member Function Documentation

◆ Release()

void vtkCocoaAutoreleasePool::Release ( )

Release the pool to reclaim the memory.

When using this class from Python, call this method at the end of the current scope, since object lifetimes in Python are not sufficiently deterministic for basic RAII. In C++, this method is unnecessary and you can rely on the destructor to release the pool.


The documentation for this class was generated from the following file: