A class that captures the Type to filter down to using
Given the way Dart generics work, one cannot simply use the
is T /
checks and castings within an ofTypeObservable itself. Therefore, this class
was introduced to capture the type of class you'd like
ofType to filter
down to, or
cast to cast to.
new Stream.fromIterable([1, "hi"]) .ofType(new TypeToken<String>) .listen(print); // prints "hi"
- @Deprecated('Please use Observable.whereType instead')
- hashCode → int
The hash code for this object.
- runtimeType → Type
A representation of the runtime type of the object.
dynamic other) → bool
The equality operator.