FormattableText class

Text representing a Place or query prediction. The text may be used as is or formatted.

Documentation: https://developers.google.com/maps/documentation/places/web-service/reference/rest/v1/places/autocomplete#formattabletext

Inheritance
Available extensions
Annotations
  • @JsonSerializable()
  • @CopyWith()

Constructors

FormattableText.new({String? text, List<StringRange>? matches})
FormattableText.fromJson(Map<String, dynamic> json)
factory

Properties

copyWith → _$FormattableTextCWProxy

Available on FormattableText, provided by the $FormattableTextCopyWith extension

Returns a callable class that can be used as follows: instanceOfFormattableText.copyWith(...).
no setter
hashCode int
The hash code for this object.
no setterinherited
matches List<StringRange>?
A list of string ranges identifying where the input request matched in text. The ranges can be used to format specific parts of text. The substrings may not be exact matches of input if the matching was determined by criteria other than string matching (for example, spell corrections or transliterations).
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
text String?
Text that may be used as is or formatted with matches.
final

Methods

fromJsonList(List? jsonList) List<FormattableText>?
inherited
fromJsonMap(Map<String, dynamic>? json) FormattableText?
override
fromJsonString(String? json) FormattableText?
inherited
fromJsonStringList(String? jsonStringList) List<FormattableText>?
inherited
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toFieldsMask({String? parentKey}) List<String>
inherited
toJson() Map<String, dynamic>
override
toJsonMap() Map<String, dynamic>
inherited
toJsonString() String
inherited
toString() String
This is just to suggest children to implement a named constructor to support creating objects fromJson(...) and fromJsonString(...) as easy as T.build().fromJson(...) or T.build().fromJsonString(...)
inherited

Operators

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