complete method
complete can be called to complete the current flow. complete takes a closure which exposes the current flow state and is responsible for returning the new flow state.
When complete is called, the flow is popped with the new flow state.
Implementation
@override
void complete([FlowCallback<T>? callback]) {
_completed = true;
if (callback != null) _state = callback(_state);
}