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

A container for specifying rule filters. The filters determine the subset of * objects to which the rule applies. This element is required only if you specify * more than one filter.

For example:

  • If you specify both * a Prefix and a Tag filter, wrap these filters in an * And element.

  • If you specify a filter based on * multiple tags, wrap the Tag elements in an And * element.

See Also:

AWS * API Reference

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

An object key name prefix that identifies the subset of objects that the rule * applies to.

*/ inline const Aws::String& GetPrefix() const{ return m_prefix; } /** *

An object key name prefix that identifies the subset of objects that the rule * applies to.

*/ inline bool PrefixHasBeenSet() const { return m_prefixHasBeenSet; } /** *

An object key name prefix that identifies the subset of objects that the rule * applies to.

*/ inline void SetPrefix(const Aws::String& value) { m_prefixHasBeenSet = true; m_prefix = value; } /** *

An object key name prefix that identifies the subset of objects that the rule * applies to.

*/ inline void SetPrefix(Aws::String&& value) { m_prefixHasBeenSet = true; m_prefix = std::move(value); } /** *

An object key name prefix that identifies the subset of objects that the rule * applies to.

*/ inline void SetPrefix(const char* value) { m_prefixHasBeenSet = true; m_prefix.assign(value); } /** *

An object key name prefix that identifies the subset of objects that the rule * applies to.

*/ inline ReplicationRuleAndOperator& WithPrefix(const Aws::String& value) { SetPrefix(value); return *this;} /** *

An object key name prefix that identifies the subset of objects that the rule * applies to.

*/ inline ReplicationRuleAndOperator& WithPrefix(Aws::String&& value) { SetPrefix(std::move(value)); return *this;} /** *

An object key name prefix that identifies the subset of objects that the rule * applies to.

*/ inline ReplicationRuleAndOperator& WithPrefix(const char* value) { SetPrefix(value); return *this;} /** *

An array of tags that contain key and value pairs.

*/ inline const Aws::Vector& GetTags() const{ return m_tags; } /** *

An array of tags that contain key and value pairs.

*/ inline bool TagsHasBeenSet() const { return m_tagsHasBeenSet; } /** *

An array of tags that contain key and value pairs.

*/ inline void SetTags(const Aws::Vector& value) { m_tagsHasBeenSet = true; m_tags = value; } /** *

An array of tags that contain key and value pairs.

*/ inline void SetTags(Aws::Vector&& value) { m_tagsHasBeenSet = true; m_tags = std::move(value); } /** *

An array of tags that contain key and value pairs.

*/ inline ReplicationRuleAndOperator& WithTags(const Aws::Vector& value) { SetTags(value); return *this;} /** *

An array of tags that contain key and value pairs.

*/ inline ReplicationRuleAndOperator& WithTags(Aws::Vector&& value) { SetTags(std::move(value)); return *this;} /** *

An array of tags that contain key and value pairs.

*/ inline ReplicationRuleAndOperator& AddTags(const S3Tag& value) { m_tagsHasBeenSet = true; m_tags.push_back(value); return *this; } /** *

An array of tags that contain key and value pairs.

*/ inline ReplicationRuleAndOperator& AddTags(S3Tag&& value) { m_tagsHasBeenSet = true; m_tags.push_back(std::move(value)); return *this; } private: Aws::String m_prefix; bool m_prefixHasBeenSet = false; Aws::Vector m_tags; bool m_tagsHasBeenSet = false; }; } // namespace Model } // namespace S3Control } // namespace Aws