Autocomplete<T extends Object> constructor
Null safety
- {Key? key,
- required AutocompleteOptionsBuilder<
T> optionsBuilder, - AutocompleteOptionToString<
T> displayStringForOption = RawAutocomplete.defaultStringForOption, - AutocompleteFieldViewBuilder fieldViewBuilder = _defaultFieldViewBuilder,
- AutocompleteOnSelected<
T> ? onSelected, - double optionsMaxHeight = 200.0,
- AutocompleteOptionsViewBuilder<
T> ? optionsViewBuilder, - TextEditingValue? initialValue}
Creates an instance of Autocomplete.
Implementation
const Autocomplete({
super.key,
required this.optionsBuilder,
this.displayStringForOption = RawAutocomplete.defaultStringForOption,
this.fieldViewBuilder = _defaultFieldViewBuilder,
this.onSelected,
this.optionsMaxHeight = 200.0,
this.optionsViewBuilder,
this.initialValue,
}) : assert(displayStringForOption != null),
assert(optionsBuilder != null);