/** * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. * SPDX-License-Identifier: Apache-2.0. */ #pragma once #include #include #include #include #include #include namespace Aws { namespace Utils { namespace Json { class JsonValue; class JsonView; } // namespace Json } // namespace Utils namespace IVS { namespace Model { /** *

Specifies a live video stream that has been ingested and * distributed.

See Also:

AWS API * Reference

*/ class Stream { public: AWS_IVS_API Stream(); AWS_IVS_API Stream(Aws::Utils::Json::JsonView jsonValue); AWS_IVS_API Stream& operator=(Aws::Utils::Json::JsonView jsonValue); AWS_IVS_API Aws::Utils::Json::JsonValue Jsonize() const; /** *

Channel ARN for the stream.

*/ inline const Aws::String& GetChannelArn() const{ return m_channelArn; } /** *

Channel ARN for the stream.

*/ inline bool ChannelArnHasBeenSet() const { return m_channelArnHasBeenSet; } /** *

Channel ARN for the stream.

*/ inline void SetChannelArn(const Aws::String& value) { m_channelArnHasBeenSet = true; m_channelArn = value; } /** *

Channel ARN for the stream.

*/ inline void SetChannelArn(Aws::String&& value) { m_channelArnHasBeenSet = true; m_channelArn = std::move(value); } /** *

Channel ARN for the stream.

*/ inline void SetChannelArn(const char* value) { m_channelArnHasBeenSet = true; m_channelArn.assign(value); } /** *

Channel ARN for the stream.

*/ inline Stream& WithChannelArn(const Aws::String& value) { SetChannelArn(value); return *this;} /** *

Channel ARN for the stream.

*/ inline Stream& WithChannelArn(Aws::String&& value) { SetChannelArn(std::move(value)); return *this;} /** *

Channel ARN for the stream.

*/ inline Stream& WithChannelArn(const char* value) { SetChannelArn(value); return *this;} /** *

The stream’s health.

*/ inline const StreamHealth& GetHealth() const{ return m_health; } /** *

The stream’s health.

*/ inline bool HealthHasBeenSet() const { return m_healthHasBeenSet; } /** *

The stream’s health.

*/ inline void SetHealth(const StreamHealth& value) { m_healthHasBeenSet = true; m_health = value; } /** *

The stream’s health.

*/ inline void SetHealth(StreamHealth&& value) { m_healthHasBeenSet = true; m_health = std::move(value); } /** *

The stream’s health.

*/ inline Stream& WithHealth(const StreamHealth& value) { SetHealth(value); return *this;} /** *

The stream’s health.

*/ inline Stream& WithHealth(StreamHealth&& value) { SetHealth(std::move(value)); return *this;} /** *

URL of the master playlist, required by the video player to play the HLS * stream.

*/ inline const Aws::String& GetPlaybackUrl() const{ return m_playbackUrl; } /** *

URL of the master playlist, required by the video player to play the HLS * stream.

*/ inline bool PlaybackUrlHasBeenSet() const { return m_playbackUrlHasBeenSet; } /** *

URL of the master playlist, required by the video player to play the HLS * stream.

*/ inline void SetPlaybackUrl(const Aws::String& value) { m_playbackUrlHasBeenSet = true; m_playbackUrl = value; } /** *

URL of the master playlist, required by the video player to play the HLS * stream.

*/ inline void SetPlaybackUrl(Aws::String&& value) { m_playbackUrlHasBeenSet = true; m_playbackUrl = std::move(value); } /** *

URL of the master playlist, required by the video player to play the HLS * stream.

*/ inline void SetPlaybackUrl(const char* value) { m_playbackUrlHasBeenSet = true; m_playbackUrl.assign(value); } /** *

URL of the master playlist, required by the video player to play the HLS * stream.

*/ inline Stream& WithPlaybackUrl(const Aws::String& value) { SetPlaybackUrl(value); return *this;} /** *

URL of the master playlist, required by the video player to play the HLS * stream.

*/ inline Stream& WithPlaybackUrl(Aws::String&& value) { SetPlaybackUrl(std::move(value)); return *this;} /** *

URL of the master playlist, required by the video player to play the HLS * stream.

*/ inline Stream& WithPlaybackUrl(const char* value) { SetPlaybackUrl(value); return *this;} /** *

Time of the stream’s start. This is an ISO 8601 timestamp; note that this * is returned as a string.

*/ inline const Aws::Utils::DateTime& GetStartTime() const{ return m_startTime; } /** *

Time of the stream’s start. This is an ISO 8601 timestamp; note that this * is returned as a string.

*/ inline bool StartTimeHasBeenSet() const { return m_startTimeHasBeenSet; } /** *

Time of the stream’s start. This is an ISO 8601 timestamp; note that this * is returned as a string.

*/ inline void SetStartTime(const Aws::Utils::DateTime& value) { m_startTimeHasBeenSet = true; m_startTime = value; } /** *

Time of the stream’s start. This is an ISO 8601 timestamp; note that this * is returned as a string.

*/ inline void SetStartTime(Aws::Utils::DateTime&& value) { m_startTimeHasBeenSet = true; m_startTime = std::move(value); } /** *

Time of the stream’s start. This is an ISO 8601 timestamp; note that this * is returned as a string.

*/ inline Stream& WithStartTime(const Aws::Utils::DateTime& value) { SetStartTime(value); return *this;} /** *

Time of the stream’s start. This is an ISO 8601 timestamp; note that this * is returned as a string.

*/ inline Stream& WithStartTime(Aws::Utils::DateTime&& value) { SetStartTime(std::move(value)); return *this;} /** *

The stream’s state. Do not rely on the OFFLINE state, as the API * may not return it; instead, a "NotBroadcasting" error will indicate that the * stream is not live.

*/ inline const StreamState& GetState() const{ return m_state; } /** *

The stream’s state. Do not rely on the OFFLINE state, as the API * may not return it; instead, a "NotBroadcasting" error will indicate that the * stream is not live.

*/ inline bool StateHasBeenSet() const { return m_stateHasBeenSet; } /** *

The stream’s state. Do not rely on the OFFLINE state, as the API * may not return it; instead, a "NotBroadcasting" error will indicate that the * stream is not live.

*/ inline void SetState(const StreamState& value) { m_stateHasBeenSet = true; m_state = value; } /** *

The stream’s state. Do not rely on the OFFLINE state, as the API * may not return it; instead, a "NotBroadcasting" error will indicate that the * stream is not live.

*/ inline void SetState(StreamState&& value) { m_stateHasBeenSet = true; m_state = std::move(value); } /** *

The stream’s state. Do not rely on the OFFLINE state, as the API * may not return it; instead, a "NotBroadcasting" error will indicate that the * stream is not live.

*/ inline Stream& WithState(const StreamState& value) { SetState(value); return *this;} /** *

The stream’s state. Do not rely on the OFFLINE state, as the API * may not return it; instead, a "NotBroadcasting" error will indicate that the * stream is not live.

*/ inline Stream& WithState(StreamState&& value) { SetState(std::move(value)); return *this;} /** *

Unique identifier for a live or previously live stream in the specified * channel.

*/ inline const Aws::String& GetStreamId() const{ return m_streamId; } /** *

Unique identifier for a live or previously live stream in the specified * channel.

*/ inline bool StreamIdHasBeenSet() const { return m_streamIdHasBeenSet; } /** *

Unique identifier for a live or previously live stream in the specified * channel.

*/ inline void SetStreamId(const Aws::String& value) { m_streamIdHasBeenSet = true; m_streamId = value; } /** *

Unique identifier for a live or previously live stream in the specified * channel.

*/ inline void SetStreamId(Aws::String&& value) { m_streamIdHasBeenSet = true; m_streamId = std::move(value); } /** *

Unique identifier for a live or previously live stream in the specified * channel.

*/ inline void SetStreamId(const char* value) { m_streamIdHasBeenSet = true; m_streamId.assign(value); } /** *

Unique identifier for a live or previously live stream in the specified * channel.

*/ inline Stream& WithStreamId(const Aws::String& value) { SetStreamId(value); return *this;} /** *

Unique identifier for a live or previously live stream in the specified * channel.

*/ inline Stream& WithStreamId(Aws::String&& value) { SetStreamId(std::move(value)); return *this;} /** *

Unique identifier for a live or previously live stream in the specified * channel.

*/ inline Stream& WithStreamId(const char* value) { SetStreamId(value); return *this;} /** *

A count of concurrent views of the stream. Typically, a new view appears in * viewerCount within 15 seconds of when video playback starts and a * view is removed from viewerCount within 1 minute of when video * playback ends. A value of -1 indicates that the request timed out; in this case, * retry.

*/ inline long long GetViewerCount() const{ return m_viewerCount; } /** *

A count of concurrent views of the stream. Typically, a new view appears in * viewerCount within 15 seconds of when video playback starts and a * view is removed from viewerCount within 1 minute of when video * playback ends. A value of -1 indicates that the request timed out; in this case, * retry.

*/ inline bool ViewerCountHasBeenSet() const { return m_viewerCountHasBeenSet; } /** *

A count of concurrent views of the stream. Typically, a new view appears in * viewerCount within 15 seconds of when video playback starts and a * view is removed from viewerCount within 1 minute of when video * playback ends. A value of -1 indicates that the request timed out; in this case, * retry.

*/ inline void SetViewerCount(long long value) { m_viewerCountHasBeenSet = true; m_viewerCount = value; } /** *

A count of concurrent views of the stream. Typically, a new view appears in * viewerCount within 15 seconds of when video playback starts and a * view is removed from viewerCount within 1 minute of when video * playback ends. A value of -1 indicates that the request timed out; in this case, * retry.

*/ inline Stream& WithViewerCount(long long value) { SetViewerCount(value); return *this;} private: Aws::String m_channelArn; bool m_channelArnHasBeenSet = false; StreamHealth m_health; bool m_healthHasBeenSet = false; Aws::String m_playbackUrl; bool m_playbackUrlHasBeenSet = false; Aws::Utils::DateTime m_startTime; bool m_startTimeHasBeenSet = false; StreamState m_state; bool m_stateHasBeenSet = false; Aws::String m_streamId; bool m_streamIdHasBeenSet = false; long long m_viewerCount; bool m_viewerCountHasBeenSet = false; }; } // namespace Model } // namespace IVS } // namespace Aws