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/medialive/MediaLive_EXPORTS.h>
8 #include <aws/medialive/model/RtmpOutputCertificateMode.h>
9 #include <aws/medialive/model/OutputLocationRef.h>
10 #include <utility>
11 
12 namespace Aws
13 {
14 namespace Utils
15 {
16 namespace Json
17 {
18   class JsonValue;
19   class JsonView;
20 } // namespace Json
21 } // namespace Utils
22 namespace MediaLive
23 {
24 namespace Model
25 {
26 
27   /**
28    * Rtmp Output Settings<p><h3>See Also:</h3>   <a
29    * href="http://docs.aws.amazon.com/goto/WebAPI/medialive-2017-10-14/RtmpOutputSettings">AWS
30    * API Reference</a></p>
31    */
32   class AWS_MEDIALIVE_API RtmpOutputSettings
33   {
34   public:
35     RtmpOutputSettings();
36     RtmpOutputSettings(Aws::Utils::Json::JsonView jsonValue);
37     RtmpOutputSettings& operator=(Aws::Utils::Json::JsonView jsonValue);
38     Aws::Utils::Json::JsonValue Jsonize() const;
39 
40 
41     /**
42      * If set to verifyAuthenticity, verify the tls certificate chain to a trusted
43      * Certificate Authority (CA).  This will cause rtmps outputs with self-signed
44      * certificates to fail.
45      */
GetCertificateMode()46     inline const RtmpOutputCertificateMode& GetCertificateMode() const{ return m_certificateMode; }
47 
48     /**
49      * If set to verifyAuthenticity, verify the tls certificate chain to a trusted
50      * Certificate Authority (CA).  This will cause rtmps outputs with self-signed
51      * certificates to fail.
52      */
CertificateModeHasBeenSet()53     inline bool CertificateModeHasBeenSet() const { return m_certificateModeHasBeenSet; }
54 
55     /**
56      * If set to verifyAuthenticity, verify the tls certificate chain to a trusted
57      * Certificate Authority (CA).  This will cause rtmps outputs with self-signed
58      * certificates to fail.
59      */
SetCertificateMode(const RtmpOutputCertificateMode & value)60     inline void SetCertificateMode(const RtmpOutputCertificateMode& value) { m_certificateModeHasBeenSet = true; m_certificateMode = value; }
61 
62     /**
63      * If set to verifyAuthenticity, verify the tls certificate chain to a trusted
64      * Certificate Authority (CA).  This will cause rtmps outputs with self-signed
65      * certificates to fail.
66      */
SetCertificateMode(RtmpOutputCertificateMode && value)67     inline void SetCertificateMode(RtmpOutputCertificateMode&& value) { m_certificateModeHasBeenSet = true; m_certificateMode = std::move(value); }
68 
69     /**
70      * If set to verifyAuthenticity, verify the tls certificate chain to a trusted
71      * Certificate Authority (CA).  This will cause rtmps outputs with self-signed
72      * certificates to fail.
73      */
WithCertificateMode(const RtmpOutputCertificateMode & value)74     inline RtmpOutputSettings& WithCertificateMode(const RtmpOutputCertificateMode& value) { SetCertificateMode(value); return *this;}
75 
76     /**
77      * If set to verifyAuthenticity, verify the tls certificate chain to a trusted
78      * Certificate Authority (CA).  This will cause rtmps outputs with self-signed
79      * certificates to fail.
80      */
WithCertificateMode(RtmpOutputCertificateMode && value)81     inline RtmpOutputSettings& WithCertificateMode(RtmpOutputCertificateMode&& value) { SetCertificateMode(std::move(value)); return *this;}
82 
83 
84     /**
85      * Number of seconds to wait before retrying a connection to the Flash Media server
86      * if the connection is lost.
87      */
GetConnectionRetryInterval()88     inline int GetConnectionRetryInterval() const{ return m_connectionRetryInterval; }
89 
90     /**
91      * Number of seconds to wait before retrying a connection to the Flash Media server
92      * if the connection is lost.
93      */
ConnectionRetryIntervalHasBeenSet()94     inline bool ConnectionRetryIntervalHasBeenSet() const { return m_connectionRetryIntervalHasBeenSet; }
95 
96     /**
97      * Number of seconds to wait before retrying a connection to the Flash Media server
98      * if the connection is lost.
99      */
SetConnectionRetryInterval(int value)100     inline void SetConnectionRetryInterval(int value) { m_connectionRetryIntervalHasBeenSet = true; m_connectionRetryInterval = value; }
101 
102     /**
103      * Number of seconds to wait before retrying a connection to the Flash Media server
104      * if the connection is lost.
105      */
WithConnectionRetryInterval(int value)106     inline RtmpOutputSettings& WithConnectionRetryInterval(int value) { SetConnectionRetryInterval(value); return *this;}
107 
108 
109     /**
110      * The RTMP endpoint excluding the stream name (eg. rtmp://host/appname). For
111      * connection to Akamai, a username and password must be supplied. URI fields
112      * accept format identifiers.
113      */
GetDestination()114     inline const OutputLocationRef& GetDestination() const{ return m_destination; }
115 
116     /**
117      * The RTMP endpoint excluding the stream name (eg. rtmp://host/appname). For
118      * connection to Akamai, a username and password must be supplied. URI fields
119      * accept format identifiers.
120      */
DestinationHasBeenSet()121     inline bool DestinationHasBeenSet() const { return m_destinationHasBeenSet; }
122 
123     /**
124      * The RTMP endpoint excluding the stream name (eg. rtmp://host/appname). For
125      * connection to Akamai, a username and password must be supplied. URI fields
126      * accept format identifiers.
127      */
SetDestination(const OutputLocationRef & value)128     inline void SetDestination(const OutputLocationRef& value) { m_destinationHasBeenSet = true; m_destination = value; }
129 
130     /**
131      * The RTMP endpoint excluding the stream name (eg. rtmp://host/appname). For
132      * connection to Akamai, a username and password must be supplied. URI fields
133      * accept format identifiers.
134      */
SetDestination(OutputLocationRef && value)135     inline void SetDestination(OutputLocationRef&& value) { m_destinationHasBeenSet = true; m_destination = std::move(value); }
136 
137     /**
138      * The RTMP endpoint excluding the stream name (eg. rtmp://host/appname). For
139      * connection to Akamai, a username and password must be supplied. URI fields
140      * accept format identifiers.
141      */
WithDestination(const OutputLocationRef & value)142     inline RtmpOutputSettings& WithDestination(const OutputLocationRef& value) { SetDestination(value); return *this;}
143 
144     /**
145      * The RTMP endpoint excluding the stream name (eg. rtmp://host/appname). For
146      * connection to Akamai, a username and password must be supplied. URI fields
147      * accept format identifiers.
148      */
WithDestination(OutputLocationRef && value)149     inline RtmpOutputSettings& WithDestination(OutputLocationRef&& value) { SetDestination(std::move(value)); return *this;}
150 
151 
152     /**
153      * Number of retry attempts.
154      */
GetNumRetries()155     inline int GetNumRetries() const{ return m_numRetries; }
156 
157     /**
158      * Number of retry attempts.
159      */
NumRetriesHasBeenSet()160     inline bool NumRetriesHasBeenSet() const { return m_numRetriesHasBeenSet; }
161 
162     /**
163      * Number of retry attempts.
164      */
SetNumRetries(int value)165     inline void SetNumRetries(int value) { m_numRetriesHasBeenSet = true; m_numRetries = value; }
166 
167     /**
168      * Number of retry attempts.
169      */
WithNumRetries(int value)170     inline RtmpOutputSettings& WithNumRetries(int value) { SetNumRetries(value); return *this;}
171 
172   private:
173 
174     RtmpOutputCertificateMode m_certificateMode;
175     bool m_certificateModeHasBeenSet;
176 
177     int m_connectionRetryInterval;
178     bool m_connectionRetryIntervalHasBeenSet;
179 
180     OutputLocationRef m_destination;
181     bool m_destinationHasBeenSet;
182 
183     int m_numRetries;
184     bool m_numRetriesHasBeenSet;
185   };
186 
187 } // namespace Model
188 } // namespace MediaLive
189 } // namespace Aws
190