/** * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. * SPDX-License-Identifier: Apache-2.0. */ #include #include #include using namespace Aws::Utils::Json; using namespace Aws::Utils; namespace Aws { namespace Pipes { namespace Model { EcsEnvironmentFile::EcsEnvironmentFile() : m_type(EcsEnvironmentFileType::NOT_SET), m_typeHasBeenSet(false), m_valueHasBeenSet(false) { } EcsEnvironmentFile::EcsEnvironmentFile(JsonView jsonValue) : m_type(EcsEnvironmentFileType::NOT_SET), m_typeHasBeenSet(false), m_valueHasBeenSet(false) { *this = jsonValue; } EcsEnvironmentFile& EcsEnvironmentFile::operator =(JsonView jsonValue) { if(jsonValue.ValueExists("type")) { m_type = EcsEnvironmentFileTypeMapper::GetEcsEnvironmentFileTypeForName(jsonValue.GetString("type")); m_typeHasBeenSet = true; } if(jsonValue.ValueExists("value")) { m_value = jsonValue.GetString("value"); m_valueHasBeenSet = true; } return *this; } JsonValue EcsEnvironmentFile::Jsonize() const { JsonValue payload; if(m_typeHasBeenSet) { payload.WithString("type", EcsEnvironmentFileTypeMapper::GetNameForEcsEnvironmentFileType(m_type)); } if(m_valueHasBeenSet) { payload.WithString("value", m_value); } return payload; } } // namespace Model } // namespace Pipes } // namespace Aws