NSDictionary+RACSequenceAdditions.h 1.2 KB

1234567891011121314151617181920212223242526272829303132333435
  1. //
  2. // NSDictionary+RACSequenceAdditions.h
  3. // ReactiveObjC
  4. //
  5. // Created by Justin Spahr-Summers on 2012-10-29.
  6. // Copyright (c) 2012 GitHub. All rights reserved.
  7. //
  8. #import <Foundation/Foundation.h>
  9. @class RACSequence<__covariant ValueType>;
  10. @class RACTwoTuple<__covariant First, __covariant Second>;
  11. NS_ASSUME_NONNULL_BEGIN
  12. @interface NSDictionary<__covariant KeyType, __covariant ObjectType> (RACSequenceAdditions)
  13. /// Creates and returns a sequence of key/value tuples.
  14. ///
  15. /// Mutating the receiver will not affect the sequence after it's been created.
  16. @property (nonatomic, copy, readonly) RACSequence<RACTwoTuple<KeyType, ObjectType> *> *rac_sequence;
  17. /// Creates and returns a sequence corresponding to the keys in the receiver.
  18. ///
  19. /// Mutating the receiver will not affect the sequence after it's been created.
  20. @property (nonatomic, copy, readonly) RACSequence<KeyType> *rac_keySequence;
  21. /// Creates and returns a sequence corresponding to the values in the receiver.
  22. ///
  23. /// Mutating the receiver will not affect the sequence after it's been created.
  24. @property (nonatomic, copy, readonly) RACSequence<ObjectType> *rac_valueSequence;
  25. @end
  26. NS_ASSUME_NONNULL_END