MCPcopy Create free account
hub / github.com/ReactiveX/RxGo / First

Method First

observable_operator.go:1053–1057  ·  view source on GitHub ↗

First returns new Observable which emit only first item. Cannot be run in parallel.

(opts ...Option)

Source from the content-addressed store, hash-verified

1051// First returns new Observable which emit only first item.
1052// Cannot be run in parallel.
1053func (o *ObservableImpl) First(opts ...Option) OptionalSingle {
1054 return optionalSingle(o.parent, o, func() operator {
1055 return &firstOperator{}
1056 }, true, false, opts...)
1057}
1058
1059type firstOperator struct{}
1060

Callers

nothing calls this directly

Calls 1

optionalSingleFunction · 0.85

Tested by

no test coverage detected