OpenCageParameters

class OpenCageParameters(val limit: Int = PARAM_DEFAULT_LIMIT, val countryCode: List<String> = emptyList(), val noDedupe: Boolean = false, val noRecord: Boolean = false) : QueryParameters

Options for the OpenCage geocoder.

See the OpenCage for more information.

Parameters

limit

The maximum number of results we should return. Maximum allowable value is 100.

countryCode

Used only for forward geocoding. Restricts results to the specified country/territory or countries. The country code is a two letter code as defined by the ISO 3166-1 Alpha 2 standard. E.g. gb for the United Kingdom, fr for France, us for United States. Non-two letter country codes are ignored.

noDedupe

If set to false, the results will not be deduplicated.

noRecord

When set to true the query contents are not logged. Please use this parameter if you have concerns about privacy, and want us to have no record of your query. Learn more about OpenCage's approach to privacy.

Constructors

Link copied to clipboard
constructor(limit: Int = PARAM_DEFAULT_LIMIT, countryCode: List<String> = emptyList(), noDedupe: Boolean = false, noRecord: Boolean = false)

Types

Link copied to clipboard
object Companion

Properties

Link copied to clipboard
Link copied to clipboard
val limit: Int
Link copied to clipboard
val noDedupe: Boolean = false
Link copied to clipboard
val noRecord: Boolean = false
Link copied to clipboard
open override val parameters: Map<String, String>

Functions

Link copied to clipboard
open fun encode(): String
Link copied to clipboard
open fun Boolean.toInt(): Int