1 /**
2  * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
3  * SPDX-License-Identifier: Apache-2.0.
4  */
5 
6 #pragma once
7 #include <aws/s3-crt/S3Crt_EXPORTS.h>
8 #include <aws/core/utils/memory/stl/AWSString.h>
9 #include <aws/s3-crt/model/Tag.h>
10 #include <aws/s3-crt/model/IntelligentTieringAndOperator.h>
11 #include <utility>
12 
13 namespace Aws
14 {
15 namespace Utils
16 {
17 namespace Xml
18 {
19   class XmlNode;
20 } // namespace Xml
21 } // namespace Utils
22 namespace S3Crt
23 {
24 namespace Model
25 {
26 
27   /**
28    * <p>The <code>Filter</code> is used to identify objects that the S3
29    * Intelligent-Tiering configuration applies to.</p><p><h3>See Also:</h3>   <a
30    * href="http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/IntelligentTieringFilter">AWS
31    * API Reference</a></p>
32    */
33   class AWS_S3CRT_API IntelligentTieringFilter
34   {
35   public:
36     IntelligentTieringFilter();
37     IntelligentTieringFilter(const Aws::Utils::Xml::XmlNode& xmlNode);
38     IntelligentTieringFilter& operator=(const Aws::Utils::Xml::XmlNode& xmlNode);
39 
40     void AddToNode(Aws::Utils::Xml::XmlNode& parentNode) const;
41 
42 
43     /**
44      * <p>An object key name prefix that identifies the subset of objects to which the
45      * rule applies.</p>  <p>Replacement must be made for object keys
46      * containing special characters (such as carriage returns) when using XML
47      * requests. For more information, see <a
48      * href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/object-keys.html#object-key-xml-related-constraints">
49      * XML related object key constraints</a>.</p>
50      */
GetPrefix()51     inline const Aws::String& GetPrefix() const{ return m_prefix; }
52 
53     /**
54      * <p>An object key name prefix that identifies the subset of objects to which the
55      * rule applies.</p>  <p>Replacement must be made for object keys
56      * containing special characters (such as carriage returns) when using XML
57      * requests. For more information, see <a
58      * href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/object-keys.html#object-key-xml-related-constraints">
59      * XML related object key constraints</a>.</p>
60      */
PrefixHasBeenSet()61     inline bool PrefixHasBeenSet() const { return m_prefixHasBeenSet; }
62 
63     /**
64      * <p>An object key name prefix that identifies the subset of objects to which the
65      * rule applies.</p>  <p>Replacement must be made for object keys
66      * containing special characters (such as carriage returns) when using XML
67      * requests. For more information, see <a
68      * href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/object-keys.html#object-key-xml-related-constraints">
69      * XML related object key constraints</a>.</p>
70      */
SetPrefix(const Aws::String & value)71     inline void SetPrefix(const Aws::String& value) { m_prefixHasBeenSet = true; m_prefix = value; }
72 
73     /**
74      * <p>An object key name prefix that identifies the subset of objects to which the
75      * rule applies.</p>  <p>Replacement must be made for object keys
76      * containing special characters (such as carriage returns) when using XML
77      * requests. For more information, see <a
78      * href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/object-keys.html#object-key-xml-related-constraints">
79      * XML related object key constraints</a>.</p>
80      */
SetPrefix(Aws::String && value)81     inline void SetPrefix(Aws::String&& value) { m_prefixHasBeenSet = true; m_prefix = std::move(value); }
82 
83     /**
84      * <p>An object key name prefix that identifies the subset of objects to which the
85      * rule applies.</p>  <p>Replacement must be made for object keys
86      * containing special characters (such as carriage returns) when using XML
87      * requests. For more information, see <a
88      * href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/object-keys.html#object-key-xml-related-constraints">
89      * XML related object key constraints</a>.</p>
90      */
SetPrefix(const char * value)91     inline void SetPrefix(const char* value) { m_prefixHasBeenSet = true; m_prefix.assign(value); }
92 
93     /**
94      * <p>An object key name prefix that identifies the subset of objects to which the
95      * rule applies.</p>  <p>Replacement must be made for object keys
96      * containing special characters (such as carriage returns) when using XML
97      * requests. For more information, see <a
98      * href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/object-keys.html#object-key-xml-related-constraints">
99      * XML related object key constraints</a>.</p>
100      */
WithPrefix(const Aws::String & value)101     inline IntelligentTieringFilter& WithPrefix(const Aws::String& value) { SetPrefix(value); return *this;}
102 
103     /**
104      * <p>An object key name prefix that identifies the subset of objects to which the
105      * rule applies.</p>  <p>Replacement must be made for object keys
106      * containing special characters (such as carriage returns) when using XML
107      * requests. For more information, see <a
108      * href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/object-keys.html#object-key-xml-related-constraints">
109      * XML related object key constraints</a>.</p>
110      */
WithPrefix(Aws::String && value)111     inline IntelligentTieringFilter& WithPrefix(Aws::String&& value) { SetPrefix(std::move(value)); return *this;}
112 
113     /**
114      * <p>An object key name prefix that identifies the subset of objects to which the
115      * rule applies.</p>  <p>Replacement must be made for object keys
116      * containing special characters (such as carriage returns) when using XML
117      * requests. For more information, see <a
118      * href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/object-keys.html#object-key-xml-related-constraints">
119      * XML related object key constraints</a>.</p>
120      */
WithPrefix(const char * value)121     inline IntelligentTieringFilter& WithPrefix(const char* value) { SetPrefix(value); return *this;}
122 
123 
124 
GetTag()125     inline const Tag& GetTag() const{ return m_tag; }
126 
127 
TagHasBeenSet()128     inline bool TagHasBeenSet() const { return m_tagHasBeenSet; }
129 
130 
SetTag(const Tag & value)131     inline void SetTag(const Tag& value) { m_tagHasBeenSet = true; m_tag = value; }
132 
133 
SetTag(Tag && value)134     inline void SetTag(Tag&& value) { m_tagHasBeenSet = true; m_tag = std::move(value); }
135 
136 
WithTag(const Tag & value)137     inline IntelligentTieringFilter& WithTag(const Tag& value) { SetTag(value); return *this;}
138 
139 
WithTag(Tag && value)140     inline IntelligentTieringFilter& WithTag(Tag&& value) { SetTag(std::move(value)); return *this;}
141 
142 
143     /**
144      * <p>A conjunction (logical AND) of predicates, which is used in evaluating a
145      * metrics filter. The operator must have at least two predicates, and an object
146      * must match all of the predicates in order for the filter to apply.</p>
147      */
GetAnd()148     inline const IntelligentTieringAndOperator& GetAnd() const{ return m_and; }
149 
150     /**
151      * <p>A conjunction (logical AND) of predicates, which is used in evaluating a
152      * metrics filter. The operator must have at least two predicates, and an object
153      * must match all of the predicates in order for the filter to apply.</p>
154      */
AndHasBeenSet()155     inline bool AndHasBeenSet() const { return m_andHasBeenSet; }
156 
157     /**
158      * <p>A conjunction (logical AND) of predicates, which is used in evaluating a
159      * metrics filter. The operator must have at least two predicates, and an object
160      * must match all of the predicates in order for the filter to apply.</p>
161      */
SetAnd(const IntelligentTieringAndOperator & value)162     inline void SetAnd(const IntelligentTieringAndOperator& value) { m_andHasBeenSet = true; m_and = value; }
163 
164     /**
165      * <p>A conjunction (logical AND) of predicates, which is used in evaluating a
166      * metrics filter. The operator must have at least two predicates, and an object
167      * must match all of the predicates in order for the filter to apply.</p>
168      */
SetAnd(IntelligentTieringAndOperator && value)169     inline void SetAnd(IntelligentTieringAndOperator&& value) { m_andHasBeenSet = true; m_and = std::move(value); }
170 
171     /**
172      * <p>A conjunction (logical AND) of predicates, which is used in evaluating a
173      * metrics filter. The operator must have at least two predicates, and an object
174      * must match all of the predicates in order for the filter to apply.</p>
175      */
WithAnd(const IntelligentTieringAndOperator & value)176     inline IntelligentTieringFilter& WithAnd(const IntelligentTieringAndOperator& value) { SetAnd(value); return *this;}
177 
178     /**
179      * <p>A conjunction (logical AND) of predicates, which is used in evaluating a
180      * metrics filter. The operator must have at least two predicates, and an object
181      * must match all of the predicates in order for the filter to apply.</p>
182      */
WithAnd(IntelligentTieringAndOperator && value)183     inline IntelligentTieringFilter& WithAnd(IntelligentTieringAndOperator&& value) { SetAnd(std::move(value)); return *this;}
184 
185   private:
186 
187     Aws::String m_prefix;
188     bool m_prefixHasBeenSet;
189 
190     Tag m_tag;
191     bool m_tagHasBeenSet;
192 
193     IntelligentTieringAndOperator m_and;
194     bool m_andHasBeenSet;
195   };
196 
197 } // namespace Model
198 } // namespace S3Crt
199 } // namespace Aws
200