pub trait INSAutoreleasePool: PNSObject {
// Provided methods
fn m_drain(&mut self) { ... }
fn m_add_object(&mut self, object: id) { ... }
}Expand description
A trait containing all the methods for NSAutoreleasePool
Provided Methods§
Sourcefn m_drain(&mut self)
fn m_drain(&mut self)
In a reference-counted environment, releases and pops the receiver; in a garbage-collected environment, triggers garbage collection if the memory allocated since the last collection is greater than the current threshold.
Sourcefn m_add_object(&mut self, object: id)
fn m_add_object(&mut self, object: id)
Adds a given object to the active autorelease pool in the current thread.
§Arguments
object- The object to be added to the pool in the current thread.
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.