One Logo Pool Ball
Combine · IOS API REFERENCE

Publishers.Share

class · iOS 13.0+ · SDK 27.1

final class Share<Upstream> where Upstream : Publisher

A publisher that shares the output of an upstream publisher with multiple subscribers. This publisher type supports multiple subscribers, all of whom receive unchanged elements and completion states from the upstream publisher. > Tip: ``Publishers/Share`` is effectively a combination of the ``Publishers/Multicast`` and ``PassthroughSubject`` publishers, with an implicit ``ConnectablePublisher/autoconnect()``. Be aware that ``Publishers/Share`` is a class rather than a structure like most other publishers. Use this type when you need a publisher instance that uses reference semantics.

Members (0)

This type has no directly callable members in this snapshot. See the framework’s skipped declarations for unsupported APIs.

Skipped declarations

3 declarations were excluded from these bindings. Each reason comes from the generator or the iOS SDK compiler.

Publishers.Share.upstream

This declaration needs Swift generic type arguments. (no canonical witness for Upstream)

Publishers.Share.init(upstream:)

This declaration needs Swift generic type arguments. (no canonical witness for Upstream)

Publishers.Share.receive(subscriber:)

This declaration needs Swift generic type arguments. (no canonical witness for S)

All Combine types →