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/chime-sdk-messaging/ChimeSDKMessaging_EXPORTS.h>
8 #include <aws/core/utils/memory/stl/AWSString.h>
9 #include <aws/chime-sdk-messaging/model/ChannelMode.h>
10 #include <aws/chime-sdk-messaging/model/ChannelPrivacy.h>
11 #include <aws/chime-sdk-messaging/model/Identity.h>
12 #include <aws/core/utils/DateTime.h>
13 #include <utility>
14 
15 namespace Aws
16 {
17 namespace Utils
18 {
19 namespace Json
20 {
21   class JsonValue;
22   class JsonView;
23 } // namespace Json
24 } // namespace Utils
25 namespace ChimeSDKMessaging
26 {
27 namespace Model
28 {
29 
30   /**
31    * <p>The details of a channel.</p><p><h3>See Also:</h3>   <a
32    * href="http://docs.aws.amazon.com/goto/WebAPI/chime-sdk-messaging-2021-05-15/Channel">AWS
33    * API Reference</a></p>
34    */
35   class AWS_CHIMESDKMESSAGING_API Channel
36   {
37   public:
38     Channel();
39     Channel(Aws::Utils::Json::JsonView jsonValue);
40     Channel& operator=(Aws::Utils::Json::JsonView jsonValue);
41     Aws::Utils::Json::JsonValue Jsonize() const;
42 
43 
44     /**
45      * <p>The name of a channel.</p>
46      */
GetName()47     inline const Aws::String& GetName() const{ return m_name; }
48 
49     /**
50      * <p>The name of a channel.</p>
51      */
NameHasBeenSet()52     inline bool NameHasBeenSet() const { return m_nameHasBeenSet; }
53 
54     /**
55      * <p>The name of a channel.</p>
56      */
SetName(const Aws::String & value)57     inline void SetName(const Aws::String& value) { m_nameHasBeenSet = true; m_name = value; }
58 
59     /**
60      * <p>The name of a channel.</p>
61      */
SetName(Aws::String && value)62     inline void SetName(Aws::String&& value) { m_nameHasBeenSet = true; m_name = std::move(value); }
63 
64     /**
65      * <p>The name of a channel.</p>
66      */
SetName(const char * value)67     inline void SetName(const char* value) { m_nameHasBeenSet = true; m_name.assign(value); }
68 
69     /**
70      * <p>The name of a channel.</p>
71      */
WithName(const Aws::String & value)72     inline Channel& WithName(const Aws::String& value) { SetName(value); return *this;}
73 
74     /**
75      * <p>The name of a channel.</p>
76      */
WithName(Aws::String && value)77     inline Channel& WithName(Aws::String&& value) { SetName(std::move(value)); return *this;}
78 
79     /**
80      * <p>The name of a channel.</p>
81      */
WithName(const char * value)82     inline Channel& WithName(const char* value) { SetName(value); return *this;}
83 
84 
85     /**
86      * <p>The ARN of a channel.</p>
87      */
GetChannelArn()88     inline const Aws::String& GetChannelArn() const{ return m_channelArn; }
89 
90     /**
91      * <p>The ARN of a channel.</p>
92      */
ChannelArnHasBeenSet()93     inline bool ChannelArnHasBeenSet() const { return m_channelArnHasBeenSet; }
94 
95     /**
96      * <p>The ARN of a channel.</p>
97      */
SetChannelArn(const Aws::String & value)98     inline void SetChannelArn(const Aws::String& value) { m_channelArnHasBeenSet = true; m_channelArn = value; }
99 
100     /**
101      * <p>The ARN of a channel.</p>
102      */
SetChannelArn(Aws::String && value)103     inline void SetChannelArn(Aws::String&& value) { m_channelArnHasBeenSet = true; m_channelArn = std::move(value); }
104 
105     /**
106      * <p>The ARN of a channel.</p>
107      */
SetChannelArn(const char * value)108     inline void SetChannelArn(const char* value) { m_channelArnHasBeenSet = true; m_channelArn.assign(value); }
109 
110     /**
111      * <p>The ARN of a channel.</p>
112      */
WithChannelArn(const Aws::String & value)113     inline Channel& WithChannelArn(const Aws::String& value) { SetChannelArn(value); return *this;}
114 
115     /**
116      * <p>The ARN of a channel.</p>
117      */
WithChannelArn(Aws::String && value)118     inline Channel& WithChannelArn(Aws::String&& value) { SetChannelArn(std::move(value)); return *this;}
119 
120     /**
121      * <p>The ARN of a channel.</p>
122      */
WithChannelArn(const char * value)123     inline Channel& WithChannelArn(const char* value) { SetChannelArn(value); return *this;}
124 
125 
126     /**
127      * <p>The mode of the channel.</p>
128      */
GetMode()129     inline const ChannelMode& GetMode() const{ return m_mode; }
130 
131     /**
132      * <p>The mode of the channel.</p>
133      */
ModeHasBeenSet()134     inline bool ModeHasBeenSet() const { return m_modeHasBeenSet; }
135 
136     /**
137      * <p>The mode of the channel.</p>
138      */
SetMode(const ChannelMode & value)139     inline void SetMode(const ChannelMode& value) { m_modeHasBeenSet = true; m_mode = value; }
140 
141     /**
142      * <p>The mode of the channel.</p>
143      */
SetMode(ChannelMode && value)144     inline void SetMode(ChannelMode&& value) { m_modeHasBeenSet = true; m_mode = std::move(value); }
145 
146     /**
147      * <p>The mode of the channel.</p>
148      */
WithMode(const ChannelMode & value)149     inline Channel& WithMode(const ChannelMode& value) { SetMode(value); return *this;}
150 
151     /**
152      * <p>The mode of the channel.</p>
153      */
WithMode(ChannelMode && value)154     inline Channel& WithMode(ChannelMode&& value) { SetMode(std::move(value)); return *this;}
155 
156 
157     /**
158      * <p>The channel's privacy setting.</p>
159      */
GetPrivacy()160     inline const ChannelPrivacy& GetPrivacy() const{ return m_privacy; }
161 
162     /**
163      * <p>The channel's privacy setting.</p>
164      */
PrivacyHasBeenSet()165     inline bool PrivacyHasBeenSet() const { return m_privacyHasBeenSet; }
166 
167     /**
168      * <p>The channel's privacy setting.</p>
169      */
SetPrivacy(const ChannelPrivacy & value)170     inline void SetPrivacy(const ChannelPrivacy& value) { m_privacyHasBeenSet = true; m_privacy = value; }
171 
172     /**
173      * <p>The channel's privacy setting.</p>
174      */
SetPrivacy(ChannelPrivacy && value)175     inline void SetPrivacy(ChannelPrivacy&& value) { m_privacyHasBeenSet = true; m_privacy = std::move(value); }
176 
177     /**
178      * <p>The channel's privacy setting.</p>
179      */
WithPrivacy(const ChannelPrivacy & value)180     inline Channel& WithPrivacy(const ChannelPrivacy& value) { SetPrivacy(value); return *this;}
181 
182     /**
183      * <p>The channel's privacy setting.</p>
184      */
WithPrivacy(ChannelPrivacy && value)185     inline Channel& WithPrivacy(ChannelPrivacy&& value) { SetPrivacy(std::move(value)); return *this;}
186 
187 
188     /**
189      * <p>The channel's metadata.</p>
190      */
GetMetadata()191     inline const Aws::String& GetMetadata() const{ return m_metadata; }
192 
193     /**
194      * <p>The channel's metadata.</p>
195      */
MetadataHasBeenSet()196     inline bool MetadataHasBeenSet() const { return m_metadataHasBeenSet; }
197 
198     /**
199      * <p>The channel's metadata.</p>
200      */
SetMetadata(const Aws::String & value)201     inline void SetMetadata(const Aws::String& value) { m_metadataHasBeenSet = true; m_metadata = value; }
202 
203     /**
204      * <p>The channel's metadata.</p>
205      */
SetMetadata(Aws::String && value)206     inline void SetMetadata(Aws::String&& value) { m_metadataHasBeenSet = true; m_metadata = std::move(value); }
207 
208     /**
209      * <p>The channel's metadata.</p>
210      */
SetMetadata(const char * value)211     inline void SetMetadata(const char* value) { m_metadataHasBeenSet = true; m_metadata.assign(value); }
212 
213     /**
214      * <p>The channel's metadata.</p>
215      */
WithMetadata(const Aws::String & value)216     inline Channel& WithMetadata(const Aws::String& value) { SetMetadata(value); return *this;}
217 
218     /**
219      * <p>The channel's metadata.</p>
220      */
WithMetadata(Aws::String && value)221     inline Channel& WithMetadata(Aws::String&& value) { SetMetadata(std::move(value)); return *this;}
222 
223     /**
224      * <p>The channel's metadata.</p>
225      */
WithMetadata(const char * value)226     inline Channel& WithMetadata(const char* value) { SetMetadata(value); return *this;}
227 
228 
229     /**
230      * <p>The <code>AppInstanceUser</code> who created the channel.</p>
231      */
GetCreatedBy()232     inline const Identity& GetCreatedBy() const{ return m_createdBy; }
233 
234     /**
235      * <p>The <code>AppInstanceUser</code> who created the channel.</p>
236      */
CreatedByHasBeenSet()237     inline bool CreatedByHasBeenSet() const { return m_createdByHasBeenSet; }
238 
239     /**
240      * <p>The <code>AppInstanceUser</code> who created the channel.</p>
241      */
SetCreatedBy(const Identity & value)242     inline void SetCreatedBy(const Identity& value) { m_createdByHasBeenSet = true; m_createdBy = value; }
243 
244     /**
245      * <p>The <code>AppInstanceUser</code> who created the channel.</p>
246      */
SetCreatedBy(Identity && value)247     inline void SetCreatedBy(Identity&& value) { m_createdByHasBeenSet = true; m_createdBy = std::move(value); }
248 
249     /**
250      * <p>The <code>AppInstanceUser</code> who created the channel.</p>
251      */
WithCreatedBy(const Identity & value)252     inline Channel& WithCreatedBy(const Identity& value) { SetCreatedBy(value); return *this;}
253 
254     /**
255      * <p>The <code>AppInstanceUser</code> who created the channel.</p>
256      */
WithCreatedBy(Identity && value)257     inline Channel& WithCreatedBy(Identity&& value) { SetCreatedBy(std::move(value)); return *this;}
258 
259 
260     /**
261      * <p>The time at which the <code>AppInstanceUser</code> created the channel.</p>
262      */
GetCreatedTimestamp()263     inline const Aws::Utils::DateTime& GetCreatedTimestamp() const{ return m_createdTimestamp; }
264 
265     /**
266      * <p>The time at which the <code>AppInstanceUser</code> created the channel.</p>
267      */
CreatedTimestampHasBeenSet()268     inline bool CreatedTimestampHasBeenSet() const { return m_createdTimestampHasBeenSet; }
269 
270     /**
271      * <p>The time at which the <code>AppInstanceUser</code> created the channel.</p>
272      */
SetCreatedTimestamp(const Aws::Utils::DateTime & value)273     inline void SetCreatedTimestamp(const Aws::Utils::DateTime& value) { m_createdTimestampHasBeenSet = true; m_createdTimestamp = value; }
274 
275     /**
276      * <p>The time at which the <code>AppInstanceUser</code> created the channel.</p>
277      */
SetCreatedTimestamp(Aws::Utils::DateTime && value)278     inline void SetCreatedTimestamp(Aws::Utils::DateTime&& value) { m_createdTimestampHasBeenSet = true; m_createdTimestamp = std::move(value); }
279 
280     /**
281      * <p>The time at which the <code>AppInstanceUser</code> created the channel.</p>
282      */
WithCreatedTimestamp(const Aws::Utils::DateTime & value)283     inline Channel& WithCreatedTimestamp(const Aws::Utils::DateTime& value) { SetCreatedTimestamp(value); return *this;}
284 
285     /**
286      * <p>The time at which the <code>AppInstanceUser</code> created the channel.</p>
287      */
WithCreatedTimestamp(Aws::Utils::DateTime && value)288     inline Channel& WithCreatedTimestamp(Aws::Utils::DateTime&& value) { SetCreatedTimestamp(std::move(value)); return *this;}
289 
290 
291     /**
292      * <p>The time at which a member sent the last message in the channel.</p>
293      */
GetLastMessageTimestamp()294     inline const Aws::Utils::DateTime& GetLastMessageTimestamp() const{ return m_lastMessageTimestamp; }
295 
296     /**
297      * <p>The time at which a member sent the last message in the channel.</p>
298      */
LastMessageTimestampHasBeenSet()299     inline bool LastMessageTimestampHasBeenSet() const { return m_lastMessageTimestampHasBeenSet; }
300 
301     /**
302      * <p>The time at which a member sent the last message in the channel.</p>
303      */
SetLastMessageTimestamp(const Aws::Utils::DateTime & value)304     inline void SetLastMessageTimestamp(const Aws::Utils::DateTime& value) { m_lastMessageTimestampHasBeenSet = true; m_lastMessageTimestamp = value; }
305 
306     /**
307      * <p>The time at which a member sent the last message in the channel.</p>
308      */
SetLastMessageTimestamp(Aws::Utils::DateTime && value)309     inline void SetLastMessageTimestamp(Aws::Utils::DateTime&& value) { m_lastMessageTimestampHasBeenSet = true; m_lastMessageTimestamp = std::move(value); }
310 
311     /**
312      * <p>The time at which a member sent the last message in the channel.</p>
313      */
WithLastMessageTimestamp(const Aws::Utils::DateTime & value)314     inline Channel& WithLastMessageTimestamp(const Aws::Utils::DateTime& value) { SetLastMessageTimestamp(value); return *this;}
315 
316     /**
317      * <p>The time at which a member sent the last message in the channel.</p>
318      */
WithLastMessageTimestamp(Aws::Utils::DateTime && value)319     inline Channel& WithLastMessageTimestamp(Aws::Utils::DateTime&& value) { SetLastMessageTimestamp(std::move(value)); return *this;}
320 
321 
322     /**
323      * <p>The time at which a channel was last updated.</p>
324      */
GetLastUpdatedTimestamp()325     inline const Aws::Utils::DateTime& GetLastUpdatedTimestamp() const{ return m_lastUpdatedTimestamp; }
326 
327     /**
328      * <p>The time at which a channel was last updated.</p>
329      */
LastUpdatedTimestampHasBeenSet()330     inline bool LastUpdatedTimestampHasBeenSet() const { return m_lastUpdatedTimestampHasBeenSet; }
331 
332     /**
333      * <p>The time at which a channel was last updated.</p>
334      */
SetLastUpdatedTimestamp(const Aws::Utils::DateTime & value)335     inline void SetLastUpdatedTimestamp(const Aws::Utils::DateTime& value) { m_lastUpdatedTimestampHasBeenSet = true; m_lastUpdatedTimestamp = value; }
336 
337     /**
338      * <p>The time at which a channel was last updated.</p>
339      */
SetLastUpdatedTimestamp(Aws::Utils::DateTime && value)340     inline void SetLastUpdatedTimestamp(Aws::Utils::DateTime&& value) { m_lastUpdatedTimestampHasBeenSet = true; m_lastUpdatedTimestamp = std::move(value); }
341 
342     /**
343      * <p>The time at which a channel was last updated.</p>
344      */
WithLastUpdatedTimestamp(const Aws::Utils::DateTime & value)345     inline Channel& WithLastUpdatedTimestamp(const Aws::Utils::DateTime& value) { SetLastUpdatedTimestamp(value); return *this;}
346 
347     /**
348      * <p>The time at which a channel was last updated.</p>
349      */
WithLastUpdatedTimestamp(Aws::Utils::DateTime && value)350     inline Channel& WithLastUpdatedTimestamp(Aws::Utils::DateTime&& value) { SetLastUpdatedTimestamp(std::move(value)); return *this;}
351 
352 
353     /**
354      * <p>The ARN of the channel flow.</p>
355      */
GetChannelFlowArn()356     inline const Aws::String& GetChannelFlowArn() const{ return m_channelFlowArn; }
357 
358     /**
359      * <p>The ARN of the channel flow.</p>
360      */
ChannelFlowArnHasBeenSet()361     inline bool ChannelFlowArnHasBeenSet() const { return m_channelFlowArnHasBeenSet; }
362 
363     /**
364      * <p>The ARN of the channel flow.</p>
365      */
SetChannelFlowArn(const Aws::String & value)366     inline void SetChannelFlowArn(const Aws::String& value) { m_channelFlowArnHasBeenSet = true; m_channelFlowArn = value; }
367 
368     /**
369      * <p>The ARN of the channel flow.</p>
370      */
SetChannelFlowArn(Aws::String && value)371     inline void SetChannelFlowArn(Aws::String&& value) { m_channelFlowArnHasBeenSet = true; m_channelFlowArn = std::move(value); }
372 
373     /**
374      * <p>The ARN of the channel flow.</p>
375      */
SetChannelFlowArn(const char * value)376     inline void SetChannelFlowArn(const char* value) { m_channelFlowArnHasBeenSet = true; m_channelFlowArn.assign(value); }
377 
378     /**
379      * <p>The ARN of the channel flow.</p>
380      */
WithChannelFlowArn(const Aws::String & value)381     inline Channel& WithChannelFlowArn(const Aws::String& value) { SetChannelFlowArn(value); return *this;}
382 
383     /**
384      * <p>The ARN of the channel flow.</p>
385      */
WithChannelFlowArn(Aws::String && value)386     inline Channel& WithChannelFlowArn(Aws::String&& value) { SetChannelFlowArn(std::move(value)); return *this;}
387 
388     /**
389      * <p>The ARN of the channel flow.</p>
390      */
WithChannelFlowArn(const char * value)391     inline Channel& WithChannelFlowArn(const char* value) { SetChannelFlowArn(value); return *this;}
392 
393   private:
394 
395     Aws::String m_name;
396     bool m_nameHasBeenSet;
397 
398     Aws::String m_channelArn;
399     bool m_channelArnHasBeenSet;
400 
401     ChannelMode m_mode;
402     bool m_modeHasBeenSet;
403 
404     ChannelPrivacy m_privacy;
405     bool m_privacyHasBeenSet;
406 
407     Aws::String m_metadata;
408     bool m_metadataHasBeenSet;
409 
410     Identity m_createdBy;
411     bool m_createdByHasBeenSet;
412 
413     Aws::Utils::DateTime m_createdTimestamp;
414     bool m_createdTimestampHasBeenSet;
415 
416     Aws::Utils::DateTime m_lastMessageTimestamp;
417     bool m_lastMessageTimestampHasBeenSet;
418 
419     Aws::Utils::DateTime m_lastUpdatedTimestamp;
420     bool m_lastUpdatedTimestampHasBeenSet;
421 
422     Aws::String m_channelFlowArn;
423     bool m_channelFlowArnHasBeenSet;
424   };
425 
426 } // namespace Model
427 } // namespace ChimeSDKMessaging
428 } // namespace Aws
429