a zip code crypto-currency system good for red ONLY

Action.js 1.2KB

12345678910111213141516171819202122232425262728293031323334
  1. import { Subscription } from '../Subscription';
  2. /**
  3. * A unit of work to be executed in a {@link Scheduler}. An action is typically
  4. * created from within a Scheduler and an RxJS user does not need to concern
  5. * themselves about creating and manipulating an Action.
  6. *
  7. * ```ts
  8. * class Action<T> extends Subscription {
  9. * new (scheduler: Scheduler, work: (state?: T) => void);
  10. * schedule(state?: T, delay: number = 0): Subscription;
  11. * }
  12. * ```
  13. *
  14. * @class Action<T>
  15. */
  16. export class Action extends Subscription {
  17. constructor(scheduler, work) {
  18. super();
  19. }
  20. /**
  21. * Schedules this action on its parent Scheduler for execution. May be passed
  22. * some context object, `state`. May happen at some point in the future,
  23. * according to the `delay` parameter, if specified.
  24. * @param {T} [state] Some contextual data that the `work` function uses when
  25. * called by the Scheduler.
  26. * @param {number} [delay] Time to wait before executing the work, where the
  27. * time unit is implicit and defined by the Scheduler.
  28. * @return {void}
  29. */
  30. schedule(state, delay = 0) {
  31. return this;
  32. }
  33. }
  34. //# sourceMappingURL=Action.js.map