GooglePlaces Framework Reference
GMSAutocompleteMatchFragment
@interface GMSAutocompleteMatchFragment : NSObject
This class represents a matched fragment of a string. This is a contiguous range of characters
in a string, suitable for highlighting in an autocompletion UI.
-
The offset of the matched fragment. This is an index into a string. The character at this index
is the first matched character.
Declaration
Swift
var offset: UInt { get }
Objective-C
@property (nonatomic, readonly) NSUInteger offset;
-
The length of the matched fragment.
Declaration
Swift
var length: UInt { get }
Objective-C
@property (nonatomic, readonly) NSUInteger length;
-
Initializer is not available.
Declaration
Objective-C
- (nonnull instancetype)init;
Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License, and code samples are licensed under the Apache 2.0 License. For details, see the Google Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2024-11-08 UTC.
[null,null,["Last updated 2024-11-08 UTC."],[[["`GMSAutocompleteMatchFragment` highlights contiguous characters within a string for autocompletion UI purposes."],["It provides the `offset` (starting position) and `length` of the matched fragment within the original string."],["This class is intended for highlighting matched text segments and cannot be directly initialized."]]],["`GMSAutocompleteMatchFragment` represents a substring within a larger string, designated for highlighting in autocompletion interfaces. It defines two key properties: `offset`, which indicates the starting index of the matched substring, and `length`, which specifies the number of characters in the matched fragment. The initializer is unavailable, implying that instances are created elsewhere, and not directly instantiated. These properties are accessible for read operations.\n"]]