LanguagePickerBloc class

The LanguagePickerBloc handles the logic providing a state for the fetched list of languages from the LanguageService. It has a state for the currently selected language currentLanguage and an event setCurrent to update this state.

Implemented types
Annotations
  • @RxBloc()

Constructors

LanguagePickerBloc.new(LanguageService _languageService)

Properties

currentLanguage → ConnectableStream<LanguageModel>
Selected language state
no setterinherited
errors → ConnectableStream<ErrorModel?>
The error state
no setterinherited
errorState Stream<Exception>
The errors of all handled result streams.
no setterinherited
errorWithTagState Stream<ErrorWithTag>
The errors of all handled result streams along with the tag
no setterinherited
events LanguagePickerBlocEvents
no setterinherited
hashCode int
The hash code for this object.
no setterinherited
languages → ConnectableStream<List<SelectedLanguageModel>>
Provides the list of the languages. One of them should be marked as selected
no setterinherited
loading → ConnectableStream<LoadingWithTag>
The loading state
no setterinherited
loadingState Stream<bool>
The loading states without tags of all handled result streams.
no setterinherited
loadingWithTagState Stream<LoadingWithTag>
The loading states with tags of all handled result streams.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
states LanguagePickerBlocStates
no setterinherited

Methods

dispose() → void
Disposes all internally created streams
inherited
loadingForTagState(String tag) Stream<bool>
The loading states with tags of all handled result streams.
inherited
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
setCurrent(LanguageModel language) → void
Sets the current language and updates the currentLanguage state
inherited
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited