/** * 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 FraudDetector { namespace Model { DetectorVersionSummary::DetectorVersionSummary() : m_detectorVersionIdHasBeenSet(false), m_status(DetectorVersionStatus::NOT_SET), m_statusHasBeenSet(false), m_descriptionHasBeenSet(false), m_lastUpdatedTimeHasBeenSet(false) { } DetectorVersionSummary::DetectorVersionSummary(JsonView jsonValue) : m_detectorVersionIdHasBeenSet(false), m_status(DetectorVersionStatus::NOT_SET), m_statusHasBeenSet(false), m_descriptionHasBeenSet(false), m_lastUpdatedTimeHasBeenSet(false) { *this = jsonValue; } DetectorVersionSummary& DetectorVersionSummary::operator =(JsonView jsonValue) { if(jsonValue.ValueExists("detectorVersionId")) { m_detectorVersionId = jsonValue.GetString("detectorVersionId"); m_detectorVersionIdHasBeenSet = true; } if(jsonValue.ValueExists("status")) { m_status = DetectorVersionStatusMapper::GetDetectorVersionStatusForName(jsonValue.GetString("status")); m_statusHasBeenSet = true; } if(jsonValue.ValueExists("description")) { m_description = jsonValue.GetString("description"); m_descriptionHasBeenSet = true; } if(jsonValue.ValueExists("lastUpdatedTime")) { m_lastUpdatedTime = jsonValue.GetString("lastUpdatedTime"); m_lastUpdatedTimeHasBeenSet = true; } return *this; } JsonValue DetectorVersionSummary::Jsonize() const { JsonValue payload; if(m_detectorVersionIdHasBeenSet) { payload.WithString("detectorVersionId", m_detectorVersionId); } if(m_statusHasBeenSet) { payload.WithString("status", DetectorVersionStatusMapper::GetNameForDetectorVersionStatus(m_status)); } if(m_descriptionHasBeenSet) { payload.WithString("description", m_description); } if(m_lastUpdatedTimeHasBeenSet) { payload.WithString("lastUpdatedTime", m_lastUpdatedTime); } return payload; } } // namespace Model } // namespace FraudDetector } // namespace Aws