/* * 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 UpdateKey operation. /// Updates the specified properties of a given API key resource. /// public partial class UpdateKeyRequest : AmazonLocationServiceRequest { private string _description; private DateTime? _expireTime; private bool? _forceUpdate; private string _keyName; private bool? _noExpiry; private ApiKeyRestrictions _restrictions; /// /// Gets and sets the property Description. /// /// Updates the description for the API key resource. /// /// [AWSProperty(Min=0, Max=1000)] public string Description { get { return this._description; } set { this._description = value; } } // Check to see if Description property is set internal bool IsSetDescription() { return this._description != null; } /// /// Gets and sets the property ExpireTime. /// /// Updates the timestamp for when the API key resource will expire in /// ISO 8601 format: YYYY-MM-DDThh:mm:ss.sssZ. /// /// public DateTime ExpireTime { get { return this._expireTime.GetValueOrDefault(); } set { this._expireTime = value; } } // Check to see if ExpireTime property is set internal bool IsSetExpireTime() { return this._expireTime.HasValue; } /// /// Gets and sets the property ForceUpdate. /// /// The boolean flag to be included for updating ExpireTime or Restrictions /// details. /// /// /// /// Must be set to true to update an API key resource that has been used /// in the past 7 days. /// /// /// /// False if force update is not preferred /// /// /// /// Default value: False /// /// public bool ForceUpdate { get { return this._forceUpdate.GetValueOrDefault(); } set { this._forceUpdate = value; } } // Check to see if ForceUpdate property is set internal bool IsSetForceUpdate() { return this._forceUpdate.HasValue; } /// /// Gets and sets the property KeyName. /// /// The name of the API key resource to update. /// /// [AWSProperty(Required=true, Min=1, Max=100)] public string KeyName { get { return this._keyName; } set { this._keyName = value; } } // Check to see if KeyName property is set internal bool IsSetKeyName() { return this._keyName != null; } /// /// Gets and sets the property NoExpiry. /// /// Whether the API key should expire. Set to true to set the API key to /// have no expiration time. /// /// public bool NoExpiry { get { return this._noExpiry.GetValueOrDefault(); } set { this._noExpiry = value; } } // Check to see if NoExpiry property is set internal bool IsSetNoExpiry() { return this._noExpiry.HasValue; } /// /// Gets and sets the property Restrictions. /// /// Updates the API key restrictions for the API key resource. /// /// public ApiKeyRestrictions Restrictions { get { return this._restrictions; } set { this._restrictions = value; } } // Check to see if Restrictions property is set internal bool IsSetRestrictions() { return this._restrictions != null; } } }