SYSearchRequest Class Reference

Represents an interface for a search request. More...

#import <SYSearch.h>

Inheritance diagram for SYSearchRequest:
Collaboration diagram for SYSearchRequest:

Instance Methods

(nonnull instancetype) - initWithQuery:location:
 Creates a geocoder request that resolves a free text query. More...
 
(nonnull instancetype) - initWithQuery:location:boundary:
 Creates a geocoder request that resolves a free text query. More...
 

Properties

NSUInteger maxResultsCount
 The maximum number of items in the response. Default value is 10. More...
 
NSString * preferredLanguage
 NSString representing the preferred language for request responses. Default value is [[NSLocale preferredLanguages] objectAtIndex:0]. More...
 
SYSearchResultTypeFilter resultTypeFilter
 Only results of types included in filter will be returned in completion block. Default value is SYSearchResultFilterAll, means searching all result types. More...
 
NSArray< NSString * > * countryFilter
 Array of country ISO codes. If set, only results from specified countries will be returned. Default value is nil, means searching in all countries. More...
 

Detailed Description

Represents an interface for a search request.

Method Documentation

◆ initWithQuery:location:

- (nonnull instancetype) initWithQuery: (nonnull NSString *)  query
location: (nullable SYGeoCoordinate *)  coordinate 

Creates a geocoder request that resolves a free text query.

Parameters
querysearch query
coordinateposition to start search from

◆ initWithQuery:location:boundary:

- (nonnull instancetype) initWithQuery: (nonnull NSString *)  query
location: (nullable SYGeoCoordinate *)  coordinate
boundary: (nonnull SYGeoBoundingBox *)  box 

Creates a geocoder request that resolves a free text query.

Parameters
querysearch query
coordinateposition to start search from
boxbounding box for filtering search results

Property Documentation

◆ maxResultsCount

- (NSUInteger) maxResultsCount
readwritenonatomicassign

The maximum number of items in the response. Default value is 10.

◆ preferredLanguage

- (NSString*) preferredLanguage
readwritenonatomicstrong

NSString representing the preferred language for request responses. Default value is [[NSLocale preferredLanguages] objectAtIndex:0].

◆ resultTypeFilter

- (SYSearchResultTypeFilter) resultTypeFilter
readwritenonatomicassign

Only results of types included in filter will be returned in completion block. Default value is SYSearchResultFilterAll, means searching all result types.

◆ countryFilter

- (NSArray<NSString*>*) countryFilter
readwritenonatomicstrong

Array of country ISO codes. If set, only results from specified countries will be returned. Default value is nil, means searching in all countries.


The documentation for this class was generated from the following file: