Empty creates an Observable with no item and terminate immediately.
()
| 177 | |
| 178 | // Empty creates an Observable with no item and terminate immediately. |
| 179 | func Empty() Observable { |
| 180 | next := make(chan Item) |
| 181 | close(next) |
| 182 | return &ObservableImpl{ |
| 183 | iterable: newChannelIterable(next), |
| 184 | } |
| 185 | } |
| 186 | |
| 187 | // FromChannel creates a cold observable from a channel. |
| 188 | func FromChannel(next <-chan Item, opts ...Option) Observable { |
searching dependent graphs…