RACScheduler+Private.h 1022 B

12345678910111213141516171819202122232425262728293031323334
  1. //
  2. // RACScheduler+Private.h
  3. // ReactiveCocoa
  4. //
  5. // Created by Josh Abernathy on 11/29/12.
  6. // Copyright (c) 2012 GitHub, Inc. All rights reserved.
  7. //
  8. #import "RACScheduler.h"
  9. /// The thread-specific current scheduler key.
  10. extern NSString * const RACSchedulerCurrentSchedulerKey;
  11. /// A private interface for internal RAC use only.
  12. @interface RACScheduler ()
  13. /// A dedicated scheduler that fills two requirements:
  14. ///
  15. /// 1. By the time subscription happens, we need a valid +currentScheduler.
  16. /// 2. Subscription should happen as soon as possible.
  17. ///
  18. /// To fulfill those two, if we already have a valid +currentScheduler, it
  19. /// immediately executes scheduled blocks. If we don't, it will execute scheduled
  20. /// blocks with a private background scheduler.
  21. + (instancetype)subscriptionScheduler;
  22. /// Initializes the receiver with the given name.
  23. ///
  24. /// name - The name of the scheduler. If nil, a default name will be used.
  25. ///
  26. /// Returns the initialized object.
  27. - (id)initWithName:(NSString *)name;
  28. @end