Latest 0.1.0
Homepage https://github.com/zekunyan/TTGKVOGuard
License MIT
Platforms ios 6.0, requires ARC
Dependencies TTGDeallocTaskHelper
Frameworks UIKit, CoreFoundation
Authors

CI Status
Version
License
Platform

What

Auto remove KVO observer from object after the object or the observer dealloc, base on TTGDeallocTaskHelper.

Requirements

iOS 6 and later.

Installation

TTGKVOGuard is available through CocoaPods. To install
it, simply add the following line to your Podfile:

pod "TTGKVOGuard"

Usage

  1. TTGKVOGuard is default off, so you must turn it on first.
    
    #import <TTGKVOGuard/NSObject+TTGKVOGuard.h>
  • (BOOL)application:(UIApplication )application didFinishLaunchingWithOptions:(NSDictionary )launchOptions {
    // Enable the TTGKVOGuard
    [NSObject ttg_setTTGKVOGuardEnable:YES];
    return YES;
    }

  1. No more need to do. Just start coding as usual :)

Example

To run the example project, clone the repo, and run pod install from the Example directory first.

Author

zekunyan, [email protected]

License

TTGKVOGuard is available under the MIT license. See the LICENSE file for more info.

Latest podspec

{
    "name": "TTGKVOGuard",
    "version": "0.1.0",
    "summary": "Auto remove KVO observer from object after the object or its observer dealloc.",
    "description": "Auto remove KVO observer from object after the object or the observer dealloc, base on TTGDeallocTaskHelper.",
    "homepage": "https://github.com/zekunyan/TTGKVOGuard",
    "license": {
        "type": "MIT",
        "file": "LICENSE"
    },
    "authors": {
        "zekunyan": "[email protected]"
    },
    "source": {
        "git": "https://github.com/zekunyan/TTGKVOGuard.git",
        "tag": "0.1.0"
    },
    "social_media_url": "http://tutuge.me",
    "platforms": {
        "ios": "6.0"
    },
    "requires_arc": true,
    "source_files": "TTGKVOGuard/Classes/**",
    "public_header_files": "TTGKVOGuard/Classes/*.h",
    "frameworks": [
        "UIKit",
        "CoreFoundation"
    ],
    "dependencies": {
        "TTGDeallocTaskHelper": []
    }
}

Pin It on Pinterest

Share This