79 lines
1.6 KiB
C++
79 lines
1.6 KiB
C++
/**
|
|
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
* SPDX-License-Identifier: Apache-2.0.
|
|
*/
|
|
|
|
#include <aws/mediaconvert/model/CaptionSourceFramerate.h>
|
|
#include <aws/core/utils/json/JsonSerializer.h>
|
|
|
|
#include <utility>
|
|
|
|
using namespace Aws::Utils::Json;
|
|
using namespace Aws::Utils;
|
|
|
|
namespace Aws
|
|
{
|
|
namespace MediaConvert
|
|
{
|
|
namespace Model
|
|
{
|
|
|
|
CaptionSourceFramerate::CaptionSourceFramerate() :
|
|
m_framerateDenominator(0),
|
|
m_framerateDenominatorHasBeenSet(false),
|
|
m_framerateNumerator(0),
|
|
m_framerateNumeratorHasBeenSet(false)
|
|
{
|
|
}
|
|
|
|
CaptionSourceFramerate::CaptionSourceFramerate(JsonView jsonValue) :
|
|
m_framerateDenominator(0),
|
|
m_framerateDenominatorHasBeenSet(false),
|
|
m_framerateNumerator(0),
|
|
m_framerateNumeratorHasBeenSet(false)
|
|
{
|
|
*this = jsonValue;
|
|
}
|
|
|
|
CaptionSourceFramerate& CaptionSourceFramerate::operator =(JsonView jsonValue)
|
|
{
|
|
if(jsonValue.ValueExists("framerateDenominator"))
|
|
{
|
|
m_framerateDenominator = jsonValue.GetInteger("framerateDenominator");
|
|
|
|
m_framerateDenominatorHasBeenSet = true;
|
|
}
|
|
|
|
if(jsonValue.ValueExists("framerateNumerator"))
|
|
{
|
|
m_framerateNumerator = jsonValue.GetInteger("framerateNumerator");
|
|
|
|
m_framerateNumeratorHasBeenSet = true;
|
|
}
|
|
|
|
return *this;
|
|
}
|
|
|
|
JsonValue CaptionSourceFramerate::Jsonize() const
|
|
{
|
|
JsonValue payload;
|
|
|
|
if(m_framerateDenominatorHasBeenSet)
|
|
{
|
|
payload.WithInteger("framerateDenominator", m_framerateDenominator);
|
|
|
|
}
|
|
|
|
if(m_framerateNumeratorHasBeenSet)
|
|
{
|
|
payload.WithInteger("framerateNumerator", m_framerateNumerator);
|
|
|
|
}
|
|
|
|
return payload;
|
|
}
|
|
|
|
} // namespace Model
|
|
} // namespace MediaConvert
|
|
} // namespace Aws
|