/libs/ObjectAL/Support/NSMutableArray+WeakReferences.h

http://github.com/kstenerud/ObjectAL-for-iPhone · C Header · 36 lines · 7 code · 9 blank · 20 comment · 0 complexity · 6d80529cf27bb764e7320cbff80deb2b MD5 · raw file

  1. //
  2. // MutableArray-WeakReferences.h
  3. //
  4. // Created by Karl Stenerud on 05/12/09.
  5. //
  6. #import <Foundation/Foundation.h>
  7. /**
  8. * Adds to NSMutableArray the ability to create an array that keeps weak references.
  9. */
  10. @interface NSMutableArray (WeakReferences)
  11. /** Create an NSMutableArray that uses weak references.
  12. */
  13. + (id) mutableArrayUsingWeakReferences;
  14. /** Create an NSMutableArray that uses weak references.
  15. *
  16. * @param capacity The initial capacity of the array.
  17. */
  18. + (id) mutableArrayUsingWeakReferencesWithCapacity:(NSUInteger) capacity;
  19. /** Create an NSMutableArray that uses weak references (no pending autorelease).
  20. */
  21. + (id) newMutableArrayUsingWeakReferences;
  22. /** Create an NSMutableArray that uses weak references (no pending autorelease).
  23. *
  24. * @param capacity The initial capacity of the array.
  25. */
  26. + (id) newMutableArrayUsingWeakReferencesWithCapacity:(NSUInteger) capacity;
  27. @end