/* * Copyright 2010-2023 Amazon.com, Inc. or its affiliates. All Rights Reserved. * * Licensed under the Apache License, Version 2.0 (the "License"). * You may not use this file except in compliance with the License. * A copy of the License is located at * * http://aws.amazon.com/apache2.0 * * or in the "license" file accompanying this file. This file is distributed * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either * express or implied. See the License for the specific language governing * permissions and limitations under the License. */ package com.amazonaws.services.geo.model; import java.io.Serializable; import com.amazonaws.AmazonWebServiceRequest; /** *
* Reverse geocodes a given coordinate and returns a legible address. Allows you * to search for Places or points of interest near a given position. *
*/ public class SearchPlaceIndexForPositionRequest extends AmazonWebServiceRequest implements Serializable { /** ** The name of the place index resource you want to use for the search. *
*
* Constraints:
* Length: 1 - 100
* Pattern: ^[-._\w]+$
*/
private String indexName;
/**
*
* The preferred language used to return results. The value must be a valid
* BCP 47 language tag,
* for example, en
for English.
*
* This setting affects the languages used in the results, but not the * results themselves. If no language is specified, or not supported for a * particular result, the partner automatically chooses a language for the * result. *
*
* For an example, we'll use the Greek language. You search for a location
* around Athens, Greece, with the language
parameter set to
* en
. The city
in the results will most likely be
* returned as Athens
.
*
* If you set the language
parameter to el
, for
* Greek, then the city
in the results will more likely be
* returned as Αθήνα
.
*
* If the data provider does not have a value for Greek, the result will be * in a language that the provider does support. *
*
* Constraints:
* Length: 2 - 35
*/
private String language;
/**
*
* An optional parameter. The maximum number of results returned per * request. *
*
* Default value: 50
*
* Constraints:
* Range: 1 - 50
*/
private Integer maxResults;
/**
*
* Specifies the longitude and latitude of the position to query. *
** This parameter must contain a pair of numbers. The first number * represents the X coordinate, or longitude; the second number represents * the Y coordinate, or latitude. *
*
* For example, [-123.1174, 49.2847]
represents a position with
* longitude -123.1174
and latitude 49.2847
.
*
* The name of the place index resource you want to use for the search. *
*
* Constraints:
* Length: 1 - 100
* Pattern: ^[-._\w]+$
*
* @return
* The name of the place index resource you want to use for the * search. *
*/ public String getIndexName() { return indexName; } /** ** The name of the place index resource you want to use for the search. *
*
* Constraints:
* Length: 1 - 100
* Pattern: ^[-._\w]+$
*
* @param indexName
* The name of the place index resource you want to use for the * search. *
*/ public void setIndexName(String indexName) { this.indexName = indexName; } /** ** The name of the place index resource you want to use for the search. *
** Returns a reference to this object so that method calls can be chained * together. *
* Constraints:
* Length: 1 - 100
* Pattern: ^[-._\w]+$
*
* @param indexName
* The name of the place index resource you want to use for the * search. *
* @return A reference to this updated object so that method calls can be * chained together. */ public SearchPlaceIndexForPositionRequest withIndexName(String indexName) { this.indexName = indexName; return this; } /** *
* The preferred language used to return results. The value must be a valid
* BCP 47 language tag,
* for example, en
for English.
*
* This setting affects the languages used in the results, but not the * results themselves. If no language is specified, or not supported for a * particular result, the partner automatically chooses a language for the * result. *
*
* For an example, we'll use the Greek language. You search for a location
* around Athens, Greece, with the language
parameter set to
* en
. The city
in the results will most likely be
* returned as Athens
.
*
* If you set the language
parameter to el
, for
* Greek, then the city
in the results will more likely be
* returned as Αθήνα
.
*
* If the data provider does not have a value for Greek, the result will be * in a language that the provider does support. *
*
* Constraints:
* Length: 2 - 35
*
* @return
* The preferred language used to return results. The value must be
* a valid BCP 47
* language tag, for example, en
for English.
*
* This setting affects the languages used in the results, but not * the results themselves. If no language is specified, or not * supported for a particular result, the partner automatically * chooses a language for the result. *
*
* For an example, we'll use the Greek language. You search for a
* location around Athens, Greece, with the language
* parameter set to en
. The city
in the
* results will most likely be returned as Athens
.
*
* If you set the language
parameter to el
* , for Greek, then the city
in the results will more
* likely be returned as Αθήνα
.
*
* If the data provider does not have a value for Greek, the result * will be in a language that the provider does support. *
*/ public String getLanguage() { return language; } /** *
* The preferred language used to return results. The value must be a valid
* BCP 47 language tag,
* for example, en
for English.
*
* This setting affects the languages used in the results, but not the * results themselves. If no language is specified, or not supported for a * particular result, the partner automatically chooses a language for the * result. *
*
* For an example, we'll use the Greek language. You search for a location
* around Athens, Greece, with the language
parameter set to
* en
. The city
in the results will most likely be
* returned as Athens
.
*
* If you set the language
parameter to el
, for
* Greek, then the city
in the results will more likely be
* returned as Αθήνα
.
*
* If the data provider does not have a value for Greek, the result will be * in a language that the provider does support. *
*
* Constraints:
* Length: 2 - 35
*
* @param language
* The preferred language used to return results. The value must
* be a valid BCP
* 47 language tag, for example, en
for English.
*
* This setting affects the languages used in the results, but * not the results themselves. If no language is specified, or * not supported for a particular result, the partner * automatically chooses a language for the result. *
*
* For an example, we'll use the Greek language. You search for a
* location around Athens, Greece, with the language
* parameter set to en
. The city
in the
* results will most likely be returned as Athens
.
*
* If you set the language
parameter to
* el
, for Greek, then the city
in the
* results will more likely be returned as Αθήνα
.
*
* If the data provider does not have a value for Greek, the * result will be in a language that the provider does support. *
*/ public void setLanguage(String language) { this.language = language; } /** *
* The preferred language used to return results. The value must be a valid
* BCP 47 language tag,
* for example, en
for English.
*
* This setting affects the languages used in the results, but not the * results themselves. If no language is specified, or not supported for a * particular result, the partner automatically chooses a language for the * result. *
*
* For an example, we'll use the Greek language. You search for a location
* around Athens, Greece, with the language
parameter set to
* en
. The city
in the results will most likely be
* returned as Athens
.
*
* If you set the language
parameter to el
, for
* Greek, then the city
in the results will more likely be
* returned as Αθήνα
.
*
* If the data provider does not have a value for Greek, the result will be * in a language that the provider does support. *
** Returns a reference to this object so that method calls can be chained * together. *
* Constraints:
* Length: 2 - 35
*
* @param language
* The preferred language used to return results. The value must
* be a valid BCP
* 47 language tag, for example, en
for English.
*
* This setting affects the languages used in the results, but * not the results themselves. If no language is specified, or * not supported for a particular result, the partner * automatically chooses a language for the result. *
*
* For an example, we'll use the Greek language. You search for a
* location around Athens, Greece, with the language
* parameter set to en
. The city
in the
* results will most likely be returned as Athens
.
*
* If you set the language
parameter to
* el
, for Greek, then the city
in the
* results will more likely be returned as Αθήνα
.
*
* If the data provider does not have a value for Greek, the * result will be in a language that the provider does support. *
* @return A reference to this updated object so that method calls can be * chained together. */ public SearchPlaceIndexForPositionRequest withLanguage(String language) { this.language = language; return this; } /** ** An optional parameter. The maximum number of results returned per * request. *
*
* Default value: 50
*
* Constraints:
* Range: 1 - 50
*
* @return
* An optional parameter. The maximum number of results returned per * request. *
*
* Default value: 50
*
* An optional parameter. The maximum number of results returned per * request. *
*
* Default value: 50
*
* Constraints:
* Range: 1 - 50
*
* @param maxResults
* An optional parameter. The maximum number of results returned * per request. *
*
* Default value: 50
*
* An optional parameter. The maximum number of results returned per * request. *
*
* Default value: 50
*
* Returns a reference to this object so that method calls can be chained * together. *
* Constraints:
* Range: 1 - 50
*
* @param maxResults
* An optional parameter. The maximum number of results returned * per request. *
*
* Default value: 50
*
* Specifies the longitude and latitude of the position to query. *
** This parameter must contain a pair of numbers. The first number * represents the X coordinate, or longitude; the second number represents * the Y coordinate, or latitude. *
*
* For example, [-123.1174, 49.2847]
represents a position with
* longitude -123.1174
and latitude 49.2847
.
*
* Specifies the longitude and latitude of the position to query. *
** This parameter must contain a pair of numbers. The first number * represents the X coordinate, or longitude; the second number * represents the Y coordinate, or latitude. *
*
* For example, [-123.1174, 49.2847]
represents a
* position with longitude -123.1174
and latitude
* 49.2847
.
*
* Specifies the longitude and latitude of the position to query. *
** This parameter must contain a pair of numbers. The first number * represents the X coordinate, or longitude; the second number represents * the Y coordinate, or latitude. *
*
* For example, [-123.1174, 49.2847]
represents a position with
* longitude -123.1174
and latitude 49.2847
.
*
* Specifies the longitude and latitude of the position to query. *
** This parameter must contain a pair of numbers. The first * number represents the X coordinate, or longitude; the second * number represents the Y coordinate, or latitude. *
*
* For example, [-123.1174, 49.2847]
represents a
* position with longitude -123.1174
and latitude
* 49.2847
.
*
* Specifies the longitude and latitude of the position to query. *
** This parameter must contain a pair of numbers. The first number * represents the X coordinate, or longitude; the second number represents * the Y coordinate, or latitude. *
*
* For example, [-123.1174, 49.2847]
represents a position with
* longitude -123.1174
and latitude 49.2847
.
*
* Returns a reference to this object so that method calls can be chained * together. * * @param position
* Specifies the longitude and latitude of the position to query. *
** This parameter must contain a pair of numbers. The first * number represents the X coordinate, or longitude; the second * number represents the Y coordinate, or latitude. *
*
* For example, [-123.1174, 49.2847]
represents a
* position with longitude -123.1174
and latitude
* 49.2847
.
*
* Specifies the longitude and latitude of the position to query. *
** This parameter must contain a pair of numbers. The first number * represents the X coordinate, or longitude; the second number represents * the Y coordinate, or latitude. *
*
* For example, [-123.1174, 49.2847]
represents a position with
* longitude -123.1174
and latitude 49.2847
.
*
* Returns a reference to this object so that method calls can be chained * together. * * @param position
* Specifies the longitude and latitude of the position to query. *
** This parameter must contain a pair of numbers. The first * number represents the X coordinate, or longitude; the second * number represents the Y coordinate, or latitude. *
*
* For example, [-123.1174, 49.2847]
represents a
* position with longitude -123.1174
and latitude
* 49.2847
.
*