/** * 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 Detective { namespace Model { Account::Account() : m_accountIdHasBeenSet(false), m_emailAddressHasBeenSet(false) { } Account::Account(JsonView jsonValue) : m_accountIdHasBeenSet(false), m_emailAddressHasBeenSet(false) { *this = jsonValue; } Account& Account::operator =(JsonView jsonValue) { if(jsonValue.ValueExists("AccountId")) { m_accountId = jsonValue.GetString("AccountId"); m_accountIdHasBeenSet = true; } if(jsonValue.ValueExists("EmailAddress")) { m_emailAddress = jsonValue.GetString("EmailAddress"); m_emailAddressHasBeenSet = true; } return *this; } JsonValue Account::Jsonize() const { JsonValue payload; if(m_accountIdHasBeenSet) { payload.WithString("AccountId", m_accountId); } if(m_emailAddressHasBeenSet) { payload.WithString("EmailAddress", m_emailAddress); } return payload; } } // namespace Model } // namespace Detective } // namespace Aws