NSObject+YYAddForARC.h 648 B

12345678910111213141516171819202122232425262728293031
  1. //
  2. // NSObject+YYAddForARC.h
  3. // YYKit <https://github.com/ibireme/YYKit>
  4. //
  5. // Created by ibireme on 13/12/15.
  6. // Copyright (c) 2015 ibireme.
  7. //
  8. // This source code is licensed under the MIT-style license found in the
  9. // LICENSE file in the root directory of this source tree.
  10. //
  11. #import <Foundation/Foundation.h>
  12. /**
  13. Debug method for NSObject when using ARC.
  14. */
  15. @interface NSObject (YYAddForARC)
  16. /// Same as `retain`
  17. - (instancetype)arcDebugRetain;
  18. /// Same as `release`
  19. - (oneway void)arcDebugRelease;
  20. /// Same as `autorelease`
  21. - (instancetype)arcDebugAutorelease;
  22. /// Same as `retainCount`
  23. - (NSUInteger)arcDebugRetainCount;
  24. @end