/** * 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 PersonalizeEvents { namespace Model { Item::Item() : m_itemIdHasBeenSet(false), m_propertiesHasBeenSet(false) { } Item::Item(JsonView jsonValue) : m_itemIdHasBeenSet(false), m_propertiesHasBeenSet(false) { *this = jsonValue; } Item& Item::operator =(JsonView jsonValue) { if(jsonValue.ValueExists("itemId")) { m_itemId = jsonValue.GetString("itemId"); m_itemIdHasBeenSet = true; } if(jsonValue.ValueExists("properties")) { m_properties = jsonValue.GetString("properties"); m_propertiesHasBeenSet = true; } return *this; } JsonValue Item::Jsonize() const { JsonValue payload; if(m_itemIdHasBeenSet) { payload.WithString("itemId", m_itemId); } if(m_propertiesHasBeenSet) { payload.WithString("properties", m_properties); } return payload; } } // namespace Model } // namespace PersonalizeEvents } // namespace Aws