attachToPool method
void
attachToPool(
- void releaseToPool()
Registers the callback that returns this component to its pool —
typically () => pool.release(this). Call once, right after
ObjectPool.acquire() hands this instance out and before adding it
to the component tree.
Implementation
void attachToPool(void Function() releaseToPool) {
_releaseToPool = releaseToPool;
}