/** * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. * SPDX-License-Identifier: Apache-2.0. */ #include #include #include using namespace Aws::ManagedBlockchain::Model; using namespace Aws::Utils::Json; using namespace Aws::Utils; CreateAccessorRequest::CreateAccessorRequest() : m_clientRequestToken(Aws::Utils::UUID::PseudoRandomUUID()), m_clientRequestTokenHasBeenSet(true), m_accessorType(AccessorType::NOT_SET), m_accessorTypeHasBeenSet(false), m_tagsHasBeenSet(false) { } Aws::String CreateAccessorRequest::SerializePayload() const { JsonValue payload; if(m_clientRequestTokenHasBeenSet) { payload.WithString("ClientRequestToken", m_clientRequestToken); } if(m_accessorTypeHasBeenSet) { payload.WithString("AccessorType", AccessorTypeMapper::GetNameForAccessorType(m_accessorType)); } if(m_tagsHasBeenSet) { JsonValue tagsJsonMap; for(auto& tagsItem : m_tags) { tagsJsonMap.WithString(tagsItem.first, tagsItem.second); } payload.WithObject("Tags", std::move(tagsJsonMap)); } return payload.View().WriteReadable(); }