/*
* Copyright 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.
*/
/*
* Do not modify this file. This file is generated from the location-2020-11-19.normal.json service model.
*/
using System;
using System.Collections.Generic;
using System.Xml.Serialization;
using System.Text;
using System.IO;
using System.Net;
using Amazon.Runtime;
using Amazon.Runtime.Internal;
namespace Amazon.LocationService.Model
{
///
/// Container for the parameters to the SearchPlaceIndexForPosition operation.
/// 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 partial class SearchPlaceIndexForPositionRequest : AmazonLocationServiceRequest
{
private string _indexName;
private string _key;
private string _language;
private int? _maxResults;
private List _position = new List();
///
/// Gets and sets the property IndexName.
///
/// The name of the place index resource you want to use for the search.
///
///
[AWSProperty(Required=true, Min=1, Max=100)]
public string IndexName
{
get { return this._indexName; }
set { this._indexName = value; }
}
// Check to see if IndexName property is set
internal bool IsSetIndexName()
{
return this._indexName != null;
}
///
/// Gets and sets the property Key.
///
/// The optional API
/// key to authorize the request.
///
///
[AWSProperty(Sensitive=true, Min=0, Max=1000)]
public string Key
{
get { return this._key; }
set { this._key = value; }
}
// Check to see if Key property is set
internal bool IsSetKey()
{
return this._key != null;
}
///
/// Gets and sets the property 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.
///
///
[AWSProperty(Min=2, Max=35)]
public string Language
{
get { return this._language; }
set { this._language = value; }
}
// Check to see if Language property is set
internal bool IsSetLanguage()
{
return this._language != null;
}
///
/// Gets and sets the property MaxResults.
///
/// An optional parameter. The maximum number of results returned per request.
///
///
///
/// Default value: 50
///
///
[AWSProperty(Min=1, Max=50)]
public int MaxResults
{
get { return this._maxResults.GetValueOrDefault(); }
set { this._maxResults = value; }
}
// Check to see if MaxResults property is set
internal bool IsSetMaxResults()
{
return this._maxResults.HasValue;
}
///
/// Gets and sets the property 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
.
///
///
[AWSProperty(Required=true, Sensitive=true, Min=2, Max=2)]
public List Position
{
get { return this._position; }
set { this._position = value; }
}
// Check to see if Position property is set
internal bool IsSetPosition()
{
return this._position != null && this._position.Count > 0;
}
}
}