This repository has been archived on 2025-09-14. You can view files and clone it, but cannot push or open issues or pull requests.
Files
pxz-hos-client-cpp-module/support/aws-sdk-cpp-master/aws-cpp-sdk-mq/source/model/DescribeConfigurationResult.cpp

102 lines
2.3 KiB
C++
Raw Normal View History

/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#include <aws/mq/model/DescribeConfigurationResult.h>
#include <aws/core/utils/json/JsonSerializer.h>
#include <aws/core/AmazonWebServiceResult.h>
#include <aws/core/utils/StringUtils.h>
#include <aws/core/utils/UnreferencedParam.h>
#include <utility>
using namespace Aws::MQ::Model;
using namespace Aws::Utils::Json;
using namespace Aws::Utils;
using namespace Aws;
DescribeConfigurationResult::DescribeConfigurationResult() :
m_authenticationStrategy(AuthenticationStrategy::NOT_SET),
m_engineType(EngineType::NOT_SET)
{
}
DescribeConfigurationResult::DescribeConfigurationResult(const Aws::AmazonWebServiceResult<JsonValue>& result) :
m_authenticationStrategy(AuthenticationStrategy::NOT_SET),
m_engineType(EngineType::NOT_SET)
{
*this = result;
}
DescribeConfigurationResult& DescribeConfigurationResult::operator =(const Aws::AmazonWebServiceResult<JsonValue>& result)
{
JsonView jsonValue = result.GetPayload().View();
if(jsonValue.ValueExists("arn"))
{
m_arn = jsonValue.GetString("arn");
}
if(jsonValue.ValueExists("authenticationStrategy"))
{
m_authenticationStrategy = AuthenticationStrategyMapper::GetAuthenticationStrategyForName(jsonValue.GetString("authenticationStrategy"));
}
if(jsonValue.ValueExists("created"))
{
m_created = jsonValue.GetString("created");
}
if(jsonValue.ValueExists("description"))
{
m_description = jsonValue.GetString("description");
}
if(jsonValue.ValueExists("engineType"))
{
m_engineType = EngineTypeMapper::GetEngineTypeForName(jsonValue.GetString("engineType"));
}
if(jsonValue.ValueExists("engineVersion"))
{
m_engineVersion = jsonValue.GetString("engineVersion");
}
if(jsonValue.ValueExists("id"))
{
m_id = jsonValue.GetString("id");
}
if(jsonValue.ValueExists("latestRevision"))
{
m_latestRevision = jsonValue.GetObject("latestRevision");
}
if(jsonValue.ValueExists("name"))
{
m_name = jsonValue.GetString("name");
}
if(jsonValue.ValueExists("tags"))
{
Aws::Map<Aws::String, JsonView> tagsJsonMap = jsonValue.GetObject("tags").GetAllObjects();
for(auto& tagsItem : tagsJsonMap)
{
m_tags[tagsItem.first] = tagsItem.second.AsString();
}
}
return *this;
}