Dematerialize

public struct Dematerialize<Upstream> : Publisher where Upstream : Publisher, Upstream.Output : SignalConvertible

Converts a materialized publisher of Signals into the represented sequence. Fails on a malformed source sequence.

Use this operator to convert a stream of Signal values from an upstream publisher into its materially represented publisher type. Malformed sequences will fail with a DematerializationError.

For each element:

  • .subscription elements are ignored
  • .input(_) elements are unwrapped and forwarded to the subscriber
  • .completion(_) elements are forwarded within the DematerializationError wrapper

If the integrity of the upstream sequence can be guaranteed, applying the assertNoDematerializationFailure() operator to this publisher will force unwrap any errors and produce a publisher with a Failure type that matches the materially represented original sequence.