VTK  9.7.20260730
vtkCocoaAutoreleasePool Class Reference

#include <vtkCocoaAutoreleasePool.h>

Detailed Description

RAII class to create an NSAutoreleasePool.

Tests:
vtkCocoaAutoreleasePool (Tests)

Definition at line 18 of file vtkCocoaAutoreleasePool.h.

Public Member Functions

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

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: