Skip to content

BlocQuestion

The BLoC for the communication between the question container RPUIQuestionStep and the question body

This class is mainly responsible for the communication between the Question Container (RPUIQuestionStep) and the Question Body (Widgets in ui/questionbody)

Constructors

BlocQuestion

BlocQuestion()

Properties

questionReadyToProceed

Stream<bool> get questionReadyToProceed

The function to send RPQuestionBodyResult through a stream

Usually used by a QuestionBody like RPUIQuestionBody to convey it's result to its RPUIQuestionStep container. Use to send the actual AnswerValue to the QuestionContainer so that it can create the RPStepResult object. The stream through which booleans are flowing The RPUIQuestionStep listens to this stream so it's notified if it can navigate to the next step

sendReadyToProceed

void Function(bool) get sendReadyToProceed

The function to send a boolean through a stream

Usually used by a QuestionBody like RPUIQuestionBody to let its RPUIQuestionStep container know that it's finished and ready to go to the next step.

Methods

dispose

void dispose()

The stream through which RPQuestionBodyResult is flowing

The RPUIQuestionStep listens to this stream and creating the RPStepResult object based on the incoming data.