GroupedObservable
public struct GroupedObservable<Key, Element> : ObservableType
Represents an observable sequence of elements that have a common key.
-
Declaration
Swift
public typealias E = Element
-
Gets the common key.
Declaration
Swift
public let key: Key
-
Initializes grouped observable sequence with key and source observable sequence.
Declaration
Swift
public init(key: Key, source: Observable<Element>)
Parameters
key
Grouped observable sequence key
source
Observable sequence that represents sequence of elements for the key
Return Value
Grouped observable sequence of elements for the specific key
-
Subscribes
observer
to receive events for this sequence.Declaration
Swift
public func subscribe<O>(_ observer: O) -> Disposable where Element == O.E, O : ObserverType
-
Converts
self
toObservable
sequence.Declaration
Swift
public func asObservable() -> Observable<Element>