/** * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. * SPDX-License-Identifier: Apache-2.0. */ #include #include #include using namespace Aws::CodeGuruReviewer::Model; using namespace Aws::Utils::Json; using namespace Aws::Utils; AssociateRepositoryRequest::AssociateRepositoryRequest() : m_repositoryHasBeenSet(false), m_clientRequestToken(Aws::Utils::UUID::PseudoRandomUUID()), m_clientRequestTokenHasBeenSet(true), m_tagsHasBeenSet(false), m_kMSKeyDetailsHasBeenSet(false) { } Aws::String AssociateRepositoryRequest::SerializePayload() const { JsonValue payload; if(m_repositoryHasBeenSet) { payload.WithObject("Repository", m_repository.Jsonize()); } if(m_clientRequestTokenHasBeenSet) { payload.WithString("ClientRequestToken", m_clientRequestToken); } if(m_tagsHasBeenSet) { JsonValue tagsJsonMap; for(auto& tagsItem : m_tags) { tagsJsonMap.WithString(tagsItem.first, tagsItem.second); } payload.WithObject("Tags", std::move(tagsJsonMap)); } if(m_kMSKeyDetailsHasBeenSet) { payload.WithObject("KMSKeyDetails", m_kMSKeyDetails.Jsonize()); } return payload.View().WriteReadable(); }