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/HlsScte35SourceType.h> 9 #include <utility> 10 11 namespace Aws 12 { 13 namespace Utils 14 { 15 namespace Json 16 { 17 class JsonValue; 18 class JsonView; 19 } // namespace Json 20 } // namespace Utils 21 namespace MediaLive 22 { 23 namespace Model 24 { 25 26 /** 27 * Hls Input Settings<p><h3>See Also:</h3> <a 28 * href="http://docs.aws.amazon.com/goto/WebAPI/medialive-2017-10-14/HlsInputSettings">AWS 29 * API Reference</a></p> 30 */ 31 class AWS_MEDIALIVE_API HlsInputSettings 32 { 33 public: 34 HlsInputSettings(); 35 HlsInputSettings(Aws::Utils::Json::JsonView jsonValue); 36 HlsInputSettings& operator=(Aws::Utils::Json::JsonView jsonValue); 37 Aws::Utils::Json::JsonValue Jsonize() const; 38 39 40 /** 41 * When specified the HLS stream with the m3u8 BANDWIDTH that most closely matches 42 * this value will be chosen, otherwise the highest bandwidth stream in the m3u8 43 * will be chosen. The bitrate is specified in bits per second, as in an HLS 44 * manifest. 45 */ GetBandwidth()46 inline int GetBandwidth() const{ return m_bandwidth; } 47 48 /** 49 * When specified the HLS stream with the m3u8 BANDWIDTH that most closely matches 50 * this value will be chosen, otherwise the highest bandwidth stream in the m3u8 51 * will be chosen. The bitrate is specified in bits per second, as in an HLS 52 * manifest. 53 */ BandwidthHasBeenSet()54 inline bool BandwidthHasBeenSet() const { return m_bandwidthHasBeenSet; } 55 56 /** 57 * When specified the HLS stream with the m3u8 BANDWIDTH that most closely matches 58 * this value will be chosen, otherwise the highest bandwidth stream in the m3u8 59 * will be chosen. The bitrate is specified in bits per second, as in an HLS 60 * manifest. 61 */ SetBandwidth(int value)62 inline void SetBandwidth(int value) { m_bandwidthHasBeenSet = true; m_bandwidth = value; } 63 64 /** 65 * When specified the HLS stream with the m3u8 BANDWIDTH that most closely matches 66 * this value will be chosen, otherwise the highest bandwidth stream in the m3u8 67 * will be chosen. The bitrate is specified in bits per second, as in an HLS 68 * manifest. 69 */ WithBandwidth(int value)70 inline HlsInputSettings& WithBandwidth(int value) { SetBandwidth(value); return *this;} 71 72 73 /** 74 * When specified, reading of the HLS input will begin this many buffer segments 75 * from the end (most recently written segment). When not specified, the HLS input 76 * will begin with the first segment specified in the m3u8. 77 */ GetBufferSegments()78 inline int GetBufferSegments() const{ return m_bufferSegments; } 79 80 /** 81 * When specified, reading of the HLS input will begin this many buffer segments 82 * from the end (most recently written segment). When not specified, the HLS input 83 * will begin with the first segment specified in the m3u8. 84 */ BufferSegmentsHasBeenSet()85 inline bool BufferSegmentsHasBeenSet() const { return m_bufferSegmentsHasBeenSet; } 86 87 /** 88 * When specified, reading of the HLS input will begin this many buffer segments 89 * from the end (most recently written segment). When not specified, the HLS input 90 * will begin with the first segment specified in the m3u8. 91 */ SetBufferSegments(int value)92 inline void SetBufferSegments(int value) { m_bufferSegmentsHasBeenSet = true; m_bufferSegments = value; } 93 94 /** 95 * When specified, reading of the HLS input will begin this many buffer segments 96 * from the end (most recently written segment). When not specified, the HLS input 97 * will begin with the first segment specified in the m3u8. 98 */ WithBufferSegments(int value)99 inline HlsInputSettings& WithBufferSegments(int value) { SetBufferSegments(value); return *this;} 100 101 102 /** 103 * The number of consecutive times that attempts to read a manifest or segment must 104 * fail before the input is considered unavailable. 105 */ GetRetries()106 inline int GetRetries() const{ return m_retries; } 107 108 /** 109 * The number of consecutive times that attempts to read a manifest or segment must 110 * fail before the input is considered unavailable. 111 */ RetriesHasBeenSet()112 inline bool RetriesHasBeenSet() const { return m_retriesHasBeenSet; } 113 114 /** 115 * The number of consecutive times that attempts to read a manifest or segment must 116 * fail before the input is considered unavailable. 117 */ SetRetries(int value)118 inline void SetRetries(int value) { m_retriesHasBeenSet = true; m_retries = value; } 119 120 /** 121 * The number of consecutive times that attempts to read a manifest or segment must 122 * fail before the input is considered unavailable. 123 */ WithRetries(int value)124 inline HlsInputSettings& WithRetries(int value) { SetRetries(value); return *this;} 125 126 127 /** 128 * The number of seconds between retries when an attempt to read a manifest or 129 * segment fails. 130 */ GetRetryInterval()131 inline int GetRetryInterval() const{ return m_retryInterval; } 132 133 /** 134 * The number of seconds between retries when an attempt to read a manifest or 135 * segment fails. 136 */ RetryIntervalHasBeenSet()137 inline bool RetryIntervalHasBeenSet() const { return m_retryIntervalHasBeenSet; } 138 139 /** 140 * The number of seconds between retries when an attempt to read a manifest or 141 * segment fails. 142 */ SetRetryInterval(int value)143 inline void SetRetryInterval(int value) { m_retryIntervalHasBeenSet = true; m_retryInterval = value; } 144 145 /** 146 * The number of seconds between retries when an attempt to read a manifest or 147 * segment fails. 148 */ WithRetryInterval(int value)149 inline HlsInputSettings& WithRetryInterval(int value) { SetRetryInterval(value); return *this;} 150 151 152 /** 153 * Identifies the source for the SCTE-35 messages that MediaLive will ingest. 154 * Messages can be ingested from the content segments (in the stream) or from tags 155 * in the playlist (the HLS manifest). MediaLive ignores SCTE-35 information in the 156 * source that is not selected. 157 */ GetScte35Source()158 inline const HlsScte35SourceType& GetScte35Source() const{ return m_scte35Source; } 159 160 /** 161 * Identifies the source for the SCTE-35 messages that MediaLive will ingest. 162 * Messages can be ingested from the content segments (in the stream) or from tags 163 * in the playlist (the HLS manifest). MediaLive ignores SCTE-35 information in the 164 * source that is not selected. 165 */ Scte35SourceHasBeenSet()166 inline bool Scte35SourceHasBeenSet() const { return m_scte35SourceHasBeenSet; } 167 168 /** 169 * Identifies the source for the SCTE-35 messages that MediaLive will ingest. 170 * Messages can be ingested from the content segments (in the stream) or from tags 171 * in the playlist (the HLS manifest). MediaLive ignores SCTE-35 information in the 172 * source that is not selected. 173 */ SetScte35Source(const HlsScte35SourceType & value)174 inline void SetScte35Source(const HlsScte35SourceType& value) { m_scte35SourceHasBeenSet = true; m_scte35Source = value; } 175 176 /** 177 * Identifies the source for the SCTE-35 messages that MediaLive will ingest. 178 * Messages can be ingested from the content segments (in the stream) or from tags 179 * in the playlist (the HLS manifest). MediaLive ignores SCTE-35 information in the 180 * source that is not selected. 181 */ SetScte35Source(HlsScte35SourceType && value)182 inline void SetScte35Source(HlsScte35SourceType&& value) { m_scte35SourceHasBeenSet = true; m_scte35Source = std::move(value); } 183 184 /** 185 * Identifies the source for the SCTE-35 messages that MediaLive will ingest. 186 * Messages can be ingested from the content segments (in the stream) or from tags 187 * in the playlist (the HLS manifest). MediaLive ignores SCTE-35 information in the 188 * source that is not selected. 189 */ WithScte35Source(const HlsScte35SourceType & value)190 inline HlsInputSettings& WithScte35Source(const HlsScte35SourceType& value) { SetScte35Source(value); return *this;} 191 192 /** 193 * Identifies the source for the SCTE-35 messages that MediaLive will ingest. 194 * Messages can be ingested from the content segments (in the stream) or from tags 195 * in the playlist (the HLS manifest). MediaLive ignores SCTE-35 information in the 196 * source that is not selected. 197 */ WithScte35Source(HlsScte35SourceType && value)198 inline HlsInputSettings& WithScte35Source(HlsScte35SourceType&& value) { SetScte35Source(std::move(value)); return *this;} 199 200 private: 201 202 int m_bandwidth; 203 bool m_bandwidthHasBeenSet; 204 205 int m_bufferSegments; 206 bool m_bufferSegmentsHasBeenSet; 207 208 int m_retries; 209 bool m_retriesHasBeenSet; 210 211 int m_retryInterval; 212 bool m_retryIntervalHasBeenSet; 213 214 HlsScte35SourceType m_scte35Source; 215 bool m_scte35SourceHasBeenSet; 216 }; 217 218 } // namespace Model 219 } // namespace MediaLive 220 } // namespace Aws 221