LocationPicker class

Inheritance

Constructors

LocationPicker({Key? key, required ValueChanged<LocationMessage> onChange, required TIMMapWidget mapBuilder(VoidCallback onMapLoadDone, Key mapKey, dynamic onMapMoveEnd(TIMCoordinate? targetGeoPt, TIMRegionChangeReason regionChangeReason)), required LocationUtils locationUtils, TIMCoordinate? initCoordinate, bool? isUseMapSDKLocation = true})
const

Properties

hashCode int
The hash code for this object.
no setterinherited
initCoordinate TIMCoordinate?
The default center coordinate shows before positioning. 用于还未加载出来定位时,打开页面后,默认的中心点。
final
isUseMapSDKLocation bool?
To control if the poisoning ability from Map SDK is needed, if true, please make sure 'moveToCurrentLocationActionWithSearchPOIByMapSDK' been implemented correctly. 用于控制是否使用地图SDK定位能力。若使用,请确保moveToCurrentLocationActionWithSearchPOIByMapSDK方法继承正确。
final
key Key?
Controls how one widget replaces another widget in the tree.
finalinherited
locationUtils LocationUtils
LocationUtils with the TIMMapService implemented with specific Map SDK. 传入根据选定地图SDK实例化后的LocationUtils
final
mapBuilder TIMMapWidget Function(VoidCallback onMapLoadDone, Key mapKey, dynamic onMapMoveEnd(TIMCoordinate? targetGeoPt, TIMRegionChangeReason regionChangeReason))
TIMMapWidget with the inherited map widget by the Map SDK you chose. 传入根据选定地图SDK实例化后的地图组件TIMMapWidget
final
onChange ValueChanged<LocationMessage>
The onChange(LocationMessage) callback after users finish choosing the location. 【Reminder】As the location message of Tencent Cloud IM only includes one string, 'desc', so the 'LocationMessage.desc' here splicing the name and address into a string. Such as: "The University of Sydney/////Camperdown NSW 2006". The splicing format can be parsed by anywhere in this plug-in. 地理位置选择完成后的onChange事件,返回一个LocationMessage,可用于发送消息。 特别说明:由于腾讯云IM位置消息仅支持传递一个desc字符串,因此此处的LocationMessage.desc将名称及地址拼接传递,格式:"腾讯大厦/////深圳市南山区深南大道10000号"。 该拼接格式可被本插件所需地方解析,请放心使用。
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

createElement() StatefulElement
Creates a StatefulElement to manage this widget's location in the tree.
inherited
createState() State<StatefulWidget>
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}) 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