/** * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. * SPDX-License-Identifier: Apache-2.0. */ #pragma once #include #include #include namespace Aws { namespace Utils { namespace Xml { class XmlNode; } // namespace Xml } // namespace Utils namespace S3 { namespace Model { /** *

A metadata key-value pair to store with an object.

See Also:

* AWS * API Reference

*/ class AWS_S3_API MetadataEntry { public: MetadataEntry(); MetadataEntry(const Aws::Utils::Xml::XmlNode& xmlNode); MetadataEntry& operator=(const Aws::Utils::Xml::XmlNode& xmlNode); void AddToNode(Aws::Utils::Xml::XmlNode& parentNode) const; /** *

Name of the Object.

*/ inline const Aws::String& GetName() const{ return m_name; } /** *

Name of the Object.

*/ inline bool NameHasBeenSet() const { return m_nameHasBeenSet; } /** *

Name of the Object.

*/ inline void SetName(const Aws::String& value) { m_nameHasBeenSet = true; m_name = value; } /** *

Name of the Object.

*/ inline void SetName(Aws::String&& value) { m_nameHasBeenSet = true; m_name = std::move(value); } /** *

Name of the Object.

*/ inline void SetName(const char* value) { m_nameHasBeenSet = true; m_name.assign(value); } /** *

Name of the Object.

*/ inline MetadataEntry& WithName(const Aws::String& value) { SetName(value); return *this;} /** *

Name of the Object.

*/ inline MetadataEntry& WithName(Aws::String&& value) { SetName(std::move(value)); return *this;} /** *

Name of the Object.

*/ inline MetadataEntry& WithName(const char* value) { SetName(value); return *this;} /** *

Value of the Object.

*/ inline const Aws::String& GetValue() const{ return m_value; } /** *

Value of the Object.

*/ inline bool ValueHasBeenSet() const { return m_valueHasBeenSet; } /** *

Value of the Object.

*/ inline void SetValue(const Aws::String& value) { m_valueHasBeenSet = true; m_value = value; } /** *

Value of the Object.

*/ inline void SetValue(Aws::String&& value) { m_valueHasBeenSet = true; m_value = std::move(value); } /** *

Value of the Object.

*/ inline void SetValue(const char* value) { m_valueHasBeenSet = true; m_value.assign(value); } /** *

Value of the Object.

*/ inline MetadataEntry& WithValue(const Aws::String& value) { SetValue(value); return *this;} /** *

Value of the Object.

*/ inline MetadataEntry& WithValue(Aws::String&& value) { SetValue(std::move(value)); return *this;} /** *

Value of the Object.

*/ inline MetadataEntry& WithValue(const char* value) { SetValue(value); return *this;} private: Aws::String m_name; bool m_nameHasBeenSet; Aws::String m_value; bool m_valueHasBeenSet; }; } // namespace Model } // namespace S3 } // namespace Aws