PresentationController constructor
PresentationController({
- required String id,
- required CEPTriggerPayload trigger,
- void onCancel(
- PresentationController controller
Creates a controller for one delivered trigger.
onCancel lets the owner of this presentation run its ordered teardown
(dismiss the overlay, emit final signals, then settle) when the plugin
cancels. When it is omitted — or when it throws — cancelling falls back
to settling with a cancelled reason, so the release path can never
itself be the thing that wedges a CEP slot.
Implementation
PresentationController({
required this.id,
required this.trigger,
void Function(PresentationController controller)? onCancel,
}) : _onCancel = onCancel {
_presentation = _Presentation(this);
}