SimpleAddressSearchField class
- Inheritance
-
- Object
- DiagnosticableTree
- Widget
- StatefulWidget
- SimpleAddressSearchField
Constructors
-
SimpleAddressSearchField({Key? key, String? hintText = "Search address", String? labelText, String languageCode = "en", List? regionCodes, TextEditingController? textEditingController, InputDecoration? inputDecoration, String? validator(dynamic value)?, int minInputLength = 3, required ValueChanged<
Address?> onSelected, required String googleApiKey}) -
A simple address search field that uses Google Places API to fetch address suggestions.
The
googleApiKeyis required to use the Google Places API. TheonSelectedcallback is called when an address is selected. TheminInputLengthspecifies the minimum number of characters required to start searching. ThelanguageCodespecifies the language for the address suggestions. TheregionCodesspecifies the region codes to restrict the search to. ThetextEditingControllercan be used to control the text field. TheinputDecorationcan be used to customize the appearance of the text field. Thevalidatorcan be used to validate the input. ThelabelTextis the label for the text field. ThehintTextis the hint text for the text field.const
Properties
- googleApiKey → String
-
final
- hashCode → int
-
The hash code for this object.
no setterinherited
- hintText → String?
-
final
- inputDecoration → InputDecoration?
-
final
- key → Key?
-
Controls how one widget replaces another widget in the tree.
finalinherited
- labelText → String?
-
final
- languageCode → String
-
final
- minInputLength → int
-
final
-
onSelected
→ ValueChanged<
Address?> -
final
- regionCodes → List?
-
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- textEditingController → TextEditingController?
-
final
- validator → String? Function(dynamic value)?
-
final
Methods
-
createElement(
) → StatefulElement -
Creates a StatefulElement to manage this widget's location in the tree.
inherited
-
createState(
) → State< SimpleAddressSearchField> -
Creates the mutable state for this widget at a given location in the tree.
override
-
debugDescribeChildren(
) → List< DiagnosticsNode> -
Returns a list of DiagnosticsNode objects describing this node's
children.
inherited
-
debugFillProperties(
DiagnosticPropertiesBuilder properties) → void -
Add additional properties associated with the node.
inherited
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toDiagnosticsNode(
{String? name, DiagnosticsTreeStyle? style}) → DiagnosticsNode -
Returns a debug representation of the object that is used by debugging
tools and by DiagnosticsNode.toStringDeep.
inherited
-
toString(
{DiagnosticLevel minLevel = DiagnosticLevel.info}) → String -
A string representation of this object.
inherited
-
toStringDeep(
{String prefixLineOne = '', String? prefixOtherLines, DiagnosticLevel minLevel = DiagnosticLevel.debug, int wrapWidth = 65}) → String -
Returns a string representation of this node and its descendants.
inherited
-
toStringShallow(
{String joiner = ', ', DiagnosticLevel minLevel = DiagnosticLevel.debug}) → String -
Returns a one-line detailed description of the object.
inherited
-
toStringShort(
) → String -
A short, textual description of this widget.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited