/* * Copyright 2010-2014 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 dynamodb-2012-08-10.normal.json service model. */ using System; using System.Collections.Generic; using System.Xml.Serialization; using System.Text; using System.IO; using Amazon.Runtime; using Amazon.Runtime.Internal; namespace Amazon.DynamoDBv2.Model { /// /// For the UpdateItem operation, represents the attributes to be modified, /// the action to perform on each, and the new value for each. /// /// /// /// You cannot use UpdateItem to update any primary key attributes. Instead, /// you will need to delete the item, and then use PutItem to create a new /// item with new attributes. /// /// /// /// Attribute values cannot be null; string and binary type attributes must have lengths /// greater than zero; and set type attributes must not be empty. Requests with empty /// values will be rejected with a ValidationException exception. /// /// public partial class AttributeValueUpdate { private AttributeAction _action; private AttributeValue _value; /// /// Empty constructor used to set properties independently even when a simple constructor is available /// public AttributeValueUpdate() { } /// /// Instantiates AttributeValueUpdate with the parameterized properties /// /// Represents the data for an attribute. Each attribute value is described as a name-value pair. The name is the data type, and the value is the data itself. For more information, see Data Types in the Amazon DynamoDB Developer Guide. /// Specifies how to perform the update. Valid values are PUT (default), DELETE, and ADD. The behavior depends on whether the specified primary key already exists in the table. If an item with the specified Key is found in the table: If no item with the specified Key is found: public AttributeValueUpdate(AttributeValue value, AttributeAction action) { _value = value; _action = action; } /// /// Gets and sets the property Action. /// /// Specifies how to perform the update. Valid values are PUT (default), /// DELETE, and ADD. The behavior depends on whether the specified /// primary key already exists in the table. /// /// /// /// If an item with the specified Key is found in the table: /// /// /// /// If no item with the specified Key is found: /// /// /// public AttributeAction Action { get { return this._action; } set { this._action = value; } } // Check to see if Action property is set internal bool IsSetAction() { return this._action != null; } /// /// Gets and sets the property Value. /// /// Represents the data for an attribute. /// /// /// /// Each attribute value is described as a name-value pair. The name is the data type, /// and the value is the data itself. /// /// /// /// For more information, see Data /// Types in the Amazon DynamoDB Developer Guide. /// /// public AttributeValue Value { get { return this._value; } set { this._value = value; } } // Check to see if Value property is set internal bool IsSetValue() { return this._value != null; } } }