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/codestar-notifications/CodeStarNotifications_EXPORTS.h>
8 #include <aws/codestar-notifications/CodeStarNotificationsRequest.h>
9 #include <aws/core/utils/memory/stl/AWSVector.h>
10 #include <aws/core/utils/memory/stl/AWSString.h>
11 #include <aws/codestar-notifications/model/ListTargetsFilter.h>
12 #include <utility>
13 
14 namespace Aws
15 {
16 namespace CodeStarNotifications
17 {
18 namespace Model
19 {
20 
21   /**
22    */
23   class AWS_CODESTARNOTIFICATIONS_API ListTargetsRequest : public CodeStarNotificationsRequest
24   {
25   public:
26     ListTargetsRequest();
27 
28     // Service request name is the Operation name which will send this request out,
29     // each operation should has unique request name, so that we can get operation's name from this request.
30     // Note: this is not true for response, multiple operations may have the same response name,
31     // so we can not get operation's name from response.
GetServiceRequestName()32     inline virtual const char* GetServiceRequestName() const override { return "ListTargets"; }
33 
34     Aws::String SerializePayload() const override;
35 
36 
37     /**
38      * <p>The filters to use to return information by service or resource type. Valid
39      * filters include target type, target address, and target status.</p>  <p>A
40      * filter with the same name can appear more than once when used with OR
41      * statements. Filters with different names should be applied with AND
42      * statements.</p>
43      */
GetFilters()44     inline const Aws::Vector<ListTargetsFilter>& GetFilters() const{ return m_filters; }
45 
46     /**
47      * <p>The filters to use to return information by service or resource type. Valid
48      * filters include target type, target address, and target status.</p>  <p>A
49      * filter with the same name can appear more than once when used with OR
50      * statements. Filters with different names should be applied with AND
51      * statements.</p>
52      */
FiltersHasBeenSet()53     inline bool FiltersHasBeenSet() const { return m_filtersHasBeenSet; }
54 
55     /**
56      * <p>The filters to use to return information by service or resource type. Valid
57      * filters include target type, target address, and target status.</p>  <p>A
58      * filter with the same name can appear more than once when used with OR
59      * statements. Filters with different names should be applied with AND
60      * statements.</p>
61      */
SetFilters(const Aws::Vector<ListTargetsFilter> & value)62     inline void SetFilters(const Aws::Vector<ListTargetsFilter>& value) { m_filtersHasBeenSet = true; m_filters = value; }
63 
64     /**
65      * <p>The filters to use to return information by service or resource type. Valid
66      * filters include target type, target address, and target status.</p>  <p>A
67      * filter with the same name can appear more than once when used with OR
68      * statements. Filters with different names should be applied with AND
69      * statements.</p>
70      */
SetFilters(Aws::Vector<ListTargetsFilter> && value)71     inline void SetFilters(Aws::Vector<ListTargetsFilter>&& value) { m_filtersHasBeenSet = true; m_filters = std::move(value); }
72 
73     /**
74      * <p>The filters to use to return information by service or resource type. Valid
75      * filters include target type, target address, and target status.</p>  <p>A
76      * filter with the same name can appear more than once when used with OR
77      * statements. Filters with different names should be applied with AND
78      * statements.</p>
79      */
WithFilters(const Aws::Vector<ListTargetsFilter> & value)80     inline ListTargetsRequest& WithFilters(const Aws::Vector<ListTargetsFilter>& value) { SetFilters(value); return *this;}
81 
82     /**
83      * <p>The filters to use to return information by service or resource type. Valid
84      * filters include target type, target address, and target status.</p>  <p>A
85      * filter with the same name can appear more than once when used with OR
86      * statements. Filters with different names should be applied with AND
87      * statements.</p>
88      */
WithFilters(Aws::Vector<ListTargetsFilter> && value)89     inline ListTargetsRequest& WithFilters(Aws::Vector<ListTargetsFilter>&& value) { SetFilters(std::move(value)); return *this;}
90 
91     /**
92      * <p>The filters to use to return information by service or resource type. Valid
93      * filters include target type, target address, and target status.</p>  <p>A
94      * filter with the same name can appear more than once when used with OR
95      * statements. Filters with different names should be applied with AND
96      * statements.</p>
97      */
AddFilters(const ListTargetsFilter & value)98     inline ListTargetsRequest& AddFilters(const ListTargetsFilter& value) { m_filtersHasBeenSet = true; m_filters.push_back(value); return *this; }
99 
100     /**
101      * <p>The filters to use to return information by service or resource type. Valid
102      * filters include target type, target address, and target status.</p>  <p>A
103      * filter with the same name can appear more than once when used with OR
104      * statements. Filters with different names should be applied with AND
105      * statements.</p>
106      */
AddFilters(ListTargetsFilter && value)107     inline ListTargetsRequest& AddFilters(ListTargetsFilter&& value) { m_filtersHasBeenSet = true; m_filters.push_back(std::move(value)); return *this; }
108 
109 
110     /**
111      * <p>An enumeration token that, when provided in a request, returns the next batch
112      * of the results.</p>
113      */
GetNextToken()114     inline const Aws::String& GetNextToken() const{ return m_nextToken; }
115 
116     /**
117      * <p>An enumeration token that, when provided in a request, returns the next batch
118      * of the results.</p>
119      */
NextTokenHasBeenSet()120     inline bool NextTokenHasBeenSet() const { return m_nextTokenHasBeenSet; }
121 
122     /**
123      * <p>An enumeration token that, when provided in a request, returns the next batch
124      * of the results.</p>
125      */
SetNextToken(const Aws::String & value)126     inline void SetNextToken(const Aws::String& value) { m_nextTokenHasBeenSet = true; m_nextToken = value; }
127 
128     /**
129      * <p>An enumeration token that, when provided in a request, returns the next batch
130      * of the results.</p>
131      */
SetNextToken(Aws::String && value)132     inline void SetNextToken(Aws::String&& value) { m_nextTokenHasBeenSet = true; m_nextToken = std::move(value); }
133 
134     /**
135      * <p>An enumeration token that, when provided in a request, returns the next batch
136      * of the results.</p>
137      */
SetNextToken(const char * value)138     inline void SetNextToken(const char* value) { m_nextTokenHasBeenSet = true; m_nextToken.assign(value); }
139 
140     /**
141      * <p>An enumeration token that, when provided in a request, returns the next batch
142      * of the results.</p>
143      */
WithNextToken(const Aws::String & value)144     inline ListTargetsRequest& WithNextToken(const Aws::String& value) { SetNextToken(value); return *this;}
145 
146     /**
147      * <p>An enumeration token that, when provided in a request, returns the next batch
148      * of the results.</p>
149      */
WithNextToken(Aws::String && value)150     inline ListTargetsRequest& WithNextToken(Aws::String&& value) { SetNextToken(std::move(value)); return *this;}
151 
152     /**
153      * <p>An enumeration token that, when provided in a request, returns the next batch
154      * of the results.</p>
155      */
WithNextToken(const char * value)156     inline ListTargetsRequest& WithNextToken(const char* value) { SetNextToken(value); return *this;}
157 
158 
159     /**
160      * <p>A non-negative integer used to limit the number of returned results. The
161      * maximum number of results that can be returned is 100.</p>
162      */
GetMaxResults()163     inline int GetMaxResults() const{ return m_maxResults; }
164 
165     /**
166      * <p>A non-negative integer used to limit the number of returned results. The
167      * maximum number of results that can be returned is 100.</p>
168      */
MaxResultsHasBeenSet()169     inline bool MaxResultsHasBeenSet() const { return m_maxResultsHasBeenSet; }
170 
171     /**
172      * <p>A non-negative integer used to limit the number of returned results. The
173      * maximum number of results that can be returned is 100.</p>
174      */
SetMaxResults(int value)175     inline void SetMaxResults(int value) { m_maxResultsHasBeenSet = true; m_maxResults = value; }
176 
177     /**
178      * <p>A non-negative integer used to limit the number of returned results. The
179      * maximum number of results that can be returned is 100.</p>
180      */
WithMaxResults(int value)181     inline ListTargetsRequest& WithMaxResults(int value) { SetMaxResults(value); return *this;}
182 
183   private:
184 
185     Aws::Vector<ListTargetsFilter> m_filters;
186     bool m_filtersHasBeenSet;
187 
188     Aws::String m_nextToken;
189     bool m_nextTokenHasBeenSet;
190 
191     int m_maxResults;
192     bool m_maxResultsHasBeenSet;
193   };
194 
195 } // namespace Model
196 } // namespace CodeStarNotifications
197 } // namespace Aws
198