AWS SDK for C++  0.12.9
AWS SDK for C++
RepositoryTrigger.h
Go to the documentation of this file.
1 /*
2 * Copyright 2010-2016 Amazon.com, Inc. or its affiliates. All Rights Reserved.
3 *
4 * Licensed under the Apache License, Version 2.0 (the "License").
5 * You may not use this file except in compliance with the License.
6 * A copy of the License is located at
7 *
8 * http://aws.amazon.com/apache2.0
9 *
10 * or in the "license" file accompanying this file. This file is distributed
11 * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
12 * express or implied. See the License for the specific language governing
13 * permissions and limitations under the License.
14 */
15 #pragma once
20 
21 namespace Aws
22 {
23 namespace Utils
24 {
25 namespace Json
26 {
27  class JsonValue;
28 } // namespace Json
29 } // namespace Utils
30 namespace CodeCommit
31 {
32 namespace Model
33 {
34 
39  {
40  public:
43  RepositoryTrigger& operator=(const Aws::Utils::Json::JsonValue& jsonValue);
44  Aws::Utils::Json::JsonValue Jsonize() const;
45 
49  inline const Aws::String& GetName() const{ return m_name; }
50 
54  inline void SetName(const Aws::String& value) { m_nameHasBeenSet = true; m_name = value; }
55 
59  inline void SetName(Aws::String&& value) { m_nameHasBeenSet = true; m_name = value; }
60 
64  inline void SetName(const char* value) { m_nameHasBeenSet = true; m_name.assign(value); }
65 
69  inline RepositoryTrigger& WithName(const Aws::String& value) { SetName(value); return *this;}
70 
74  inline RepositoryTrigger& WithName(Aws::String&& value) { SetName(value); return *this;}
75 
79  inline RepositoryTrigger& WithName(const char* value) { SetName(value); return *this;}
80 
85  inline const Aws::String& GetDestinationArn() const{ return m_destinationArn; }
86 
91  inline void SetDestinationArn(const Aws::String& value) { m_destinationArnHasBeenSet = true; m_destinationArn = value; }
92 
97  inline void SetDestinationArn(Aws::String&& value) { m_destinationArnHasBeenSet = true; m_destinationArn = value; }
98 
103  inline void SetDestinationArn(const char* value) { m_destinationArnHasBeenSet = true; m_destinationArn.assign(value); }
104 
109  inline RepositoryTrigger& WithDestinationArn(const Aws::String& value) { SetDestinationArn(value); return *this;}
110 
115  inline RepositoryTrigger& WithDestinationArn(Aws::String&& value) { SetDestinationArn(value); return *this;}
116 
121  inline RepositoryTrigger& WithDestinationArn(const char* value) { SetDestinationArn(value); return *this;}
122 
127  inline const Aws::String& GetCustomData() const{ return m_customData; }
128 
133  inline void SetCustomData(const Aws::String& value) { m_customDataHasBeenSet = true; m_customData = value; }
134 
139  inline void SetCustomData(Aws::String&& value) { m_customDataHasBeenSet = true; m_customData = value; }
140 
145  inline void SetCustomData(const char* value) { m_customDataHasBeenSet = true; m_customData.assign(value); }
146 
151  inline RepositoryTrigger& WithCustomData(const Aws::String& value) { SetCustomData(value); return *this;}
152 
157  inline RepositoryTrigger& WithCustomData(Aws::String&& value) { SetCustomData(value); return *this;}
158 
163  inline RepositoryTrigger& WithCustomData(const char* value) { SetCustomData(value); return *this;}
164 
169  inline const Aws::Vector<Aws::String>& GetBranches() const{ return m_branches; }
170 
175  inline void SetBranches(const Aws::Vector<Aws::String>& value) { m_branchesHasBeenSet = true; m_branches = value; }
176 
181  inline void SetBranches(Aws::Vector<Aws::String>&& value) { m_branchesHasBeenSet = true; m_branches = value; }
182 
187  inline RepositoryTrigger& WithBranches(const Aws::Vector<Aws::String>& value) { SetBranches(value); return *this;}
188 
193  inline RepositoryTrigger& WithBranches(Aws::Vector<Aws::String>&& value) { SetBranches(value); return *this;}
194 
199  inline RepositoryTrigger& AddBranches(const Aws::String& value) { m_branchesHasBeenSet = true; m_branches.push_back(value); return *this; }
200 
205  inline RepositoryTrigger& AddBranches(Aws::String&& value) { m_branchesHasBeenSet = true; m_branches.push_back(value); return *this; }
206 
211  inline RepositoryTrigger& AddBranches(const char* value) { m_branchesHasBeenSet = true; m_branches.push_back(value); return *this; }
212 
219  inline const Aws::Vector<RepositoryTriggerEventEnum>& GetEvents() const{ return m_events; }
220 
227  inline void SetEvents(const Aws::Vector<RepositoryTriggerEventEnum>& value) { m_eventsHasBeenSet = true; m_events = value; }
228 
235  inline void SetEvents(Aws::Vector<RepositoryTriggerEventEnum>&& value) { m_eventsHasBeenSet = true; m_events = value; }
236 
243  inline RepositoryTrigger& WithEvents(const Aws::Vector<RepositoryTriggerEventEnum>& value) { SetEvents(value); return *this;}
244 
251  inline RepositoryTrigger& WithEvents(Aws::Vector<RepositoryTriggerEventEnum>&& value) { SetEvents(value); return *this;}
252 
259  inline RepositoryTrigger& AddEvents(const RepositoryTriggerEventEnum& value) { m_eventsHasBeenSet = true; m_events.push_back(value); return *this; }
260 
267  inline RepositoryTrigger& AddEvents(RepositoryTriggerEventEnum&& value) { m_eventsHasBeenSet = true; m_events.push_back(value); return *this; }
268 
269  private:
270  Aws::String m_name;
271  bool m_nameHasBeenSet;
272  Aws::String m_destinationArn;
273  bool m_destinationArnHasBeenSet;
274  Aws::String m_customData;
275  bool m_customDataHasBeenSet;
276  Aws::Vector<Aws::String> m_branches;
277  bool m_branchesHasBeenSet;
279  bool m_eventsHasBeenSet;
280  };
281 
282 } // namespace Model
283 } // namespace CodeCommit
284 } // namespace Aws
RepositoryTrigger & WithBranches(Aws::Vector< Aws::String > &&value)
RepositoryTrigger & WithCustomData(Aws::String &&value)
RepositoryTrigger & WithName(Aws::String &&value)
void SetEvents(const Aws::Vector< RepositoryTriggerEventEnum > &value)
RepositoryTrigger & WithBranches(const Aws::Vector< Aws::String > &value)
void SetCustomData(const Aws::String &value)
RepositoryTrigger & AddBranches(const Aws::String &value)
RepositoryTrigger & WithEvents(Aws::Vector< RepositoryTriggerEventEnum > &&value)
void SetDestinationArn(const Aws::String &value)
RepositoryTrigger & WithName(const char *value)
void SetEvents(Aws::Vector< RepositoryTriggerEventEnum > &&value)
const Aws::String & GetName() const
const Aws::String & GetDestinationArn() const
std::vector< T, Aws::Allocator< T > > Vector
Definition: AWSVector.h:27
void SetBranches(Aws::Vector< Aws::String > &&value)
RepositoryTrigger & WithDestinationArn(const char *value)
RepositoryTrigger & WithDestinationArn(const Aws::String &value)
RepositoryTrigger & WithCustomData(const char *value)
RepositoryTrigger & AddBranches(const char *value)
void SetName(const Aws::String &value)
void SetDestinationArn(Aws::String &&value)
RepositoryTrigger & WithDestinationArn(Aws::String &&value)
#define AWS_CODECOMMIT_API
const Aws::Vector< Aws::String > & GetBranches() const
RepositoryTrigger & WithCustomData(const Aws::String &value)
const Aws::Vector< RepositoryTriggerEventEnum > & GetEvents() const
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
Definition: AWSString.h:97
RepositoryTrigger & AddEvents(const RepositoryTriggerEventEnum &value)
void SetBranches(const Aws::Vector< Aws::String > &value)
RepositoryTrigger & WithEvents(const Aws::Vector< RepositoryTriggerEventEnum > &value)
RepositoryTrigger & AddEvents(RepositoryTriggerEventEnum &&value)
RepositoryTrigger & WithName(const Aws::String &value)
JSON (JavaScript Object Notation).
RepositoryTrigger & AddBranches(Aws::String &&value)
const Aws::String & GetCustomData() const