ReleasePoolOwner

public protocol ReleasePoolOwner : Retainer

Protocol for any instance that has ReleasePool. Made to proxy calls of func releaseOnDeinit(_ object: AnyObject) and func notifyDeinit(_ block: @escaping () -> Void) to ReleasePool

  • ReleasePool to proxy calls to. Perfect implementation looks like:

    public class MyService: ExecutionContext, ReleasePoolOwner {
     let releasePool = ReleasePool()
     /* other implementation */
    }
    

    Declaration

    Swift

    var releasePool: ReleasePool { get }