/** * 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 Rekognition { namespace Model { PersonDetail::PersonDetail() : m_index(0), m_indexHasBeenSet(false), m_boundingBoxHasBeenSet(false), m_faceHasBeenSet(false) { } PersonDetail::PersonDetail(JsonView jsonValue) : m_index(0), m_indexHasBeenSet(false), m_boundingBoxHasBeenSet(false), m_faceHasBeenSet(false) { *this = jsonValue; } PersonDetail& PersonDetail::operator =(JsonView jsonValue) { if(jsonValue.ValueExists("Index")) { m_index = jsonValue.GetInt64("Index"); m_indexHasBeenSet = true; } if(jsonValue.ValueExists("BoundingBox")) { m_boundingBox = jsonValue.GetObject("BoundingBox"); m_boundingBoxHasBeenSet = true; } if(jsonValue.ValueExists("Face")) { m_face = jsonValue.GetObject("Face"); m_faceHasBeenSet = true; } return *this; } JsonValue PersonDetail::Jsonize() const { JsonValue payload; if(m_indexHasBeenSet) { payload.WithInt64("Index", m_index); } if(m_boundingBoxHasBeenSet) { payload.WithObject("BoundingBox", m_boundingBox.Jsonize()); } if(m_faceHasBeenSet) { payload.WithObject("Face", m_face.Jsonize()); } return payload; } } // namespace Model } // namespace Rekognition } // namespace Aws