/** * 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 SWF { namespace Model { LambdaFunctionFailedEventAttributes::LambdaFunctionFailedEventAttributes() : m_scheduledEventId(0), m_scheduledEventIdHasBeenSet(false), m_startedEventId(0), m_startedEventIdHasBeenSet(false), m_reasonHasBeenSet(false), m_detailsHasBeenSet(false) { } LambdaFunctionFailedEventAttributes::LambdaFunctionFailedEventAttributes(JsonView jsonValue) : m_scheduledEventId(0), m_scheduledEventIdHasBeenSet(false), m_startedEventId(0), m_startedEventIdHasBeenSet(false), m_reasonHasBeenSet(false), m_detailsHasBeenSet(false) { *this = jsonValue; } LambdaFunctionFailedEventAttributes& LambdaFunctionFailedEventAttributes::operator =(JsonView jsonValue) { if(jsonValue.ValueExists("scheduledEventId")) { m_scheduledEventId = jsonValue.GetInt64("scheduledEventId"); m_scheduledEventIdHasBeenSet = true; } if(jsonValue.ValueExists("startedEventId")) { m_startedEventId = jsonValue.GetInt64("startedEventId"); m_startedEventIdHasBeenSet = true; } if(jsonValue.ValueExists("reason")) { m_reason = jsonValue.GetString("reason"); m_reasonHasBeenSet = true; } if(jsonValue.ValueExists("details")) { m_details = jsonValue.GetString("details"); m_detailsHasBeenSet = true; } return *this; } JsonValue LambdaFunctionFailedEventAttributes::Jsonize() const { JsonValue payload; if(m_scheduledEventIdHasBeenSet) { payload.WithInt64("scheduledEventId", m_scheduledEventId); } if(m_startedEventIdHasBeenSet) { payload.WithInt64("startedEventId", m_startedEventId); } if(m_reasonHasBeenSet) { payload.WithString("reason", m_reason); } if(m_detailsHasBeenSet) { payload.WithString("details", m_details); } return payload; } } // namespace Model } // namespace SWF } // namespace Aws