libtcspc.Stop

final class libtcspc.Stop(event_types, message_prefix)[source]

Bases: Node

Pass-through processor that ends the stream normally on a configured event.

When an event matching one of event_types is received, the downstream is flushed and processing ends normally (the Python binding surfaces this as EndOfProcessing, with the triggering event included in the message). All other events pass through unchanged.

Parameters:
  • event_types (Iterable[EventType]) – Event types that trigger normal termination.

  • message_prefix (str or Param[str]) – String prepended to the EndOfProcessing exception’s message, typically describing the source of the termination.

Notes

Events handled:

  • Events matching one of event_types: flush the downstream, then end processing normally.

  • All other event types: pass through unchanged.

  • End of input: pass through.

See also

tcspc::stop()

The underlying C++ factory function.