ConnectableObservableType.swift 762 B

12345678910111213141516171819
  1. //
  2. // ConnectableObservableType.swift
  3. // RxSwift
  4. //
  5. // Created by Krunoslav Zaher on 3/1/15.
  6. // Copyright © 2015 Krunoslav Zaher. All rights reserved.
  7. //
  8. /**
  9. Represents an observable sequence wrapper that can be connected and disconnected from its underlying observable sequence.
  10. */
  11. public protocol ConnectableObservableType : ObservableType {
  12. /**
  13. Connects the observable wrapper to its source. All subscribed observers will receive values from the underlying observable sequence as long as the connection is established.
  14. - returns: Disposable used to disconnect the observable wrapper from its source, causing subscribed observer to stop receiving values from the underlying observable sequence.
  15. */
  16. func connect() -> Disposable
  17. }