/** * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. * SPDX-License-Identifier: Apache-2.0. */ #include #include #include #include #include #include #include using namespace Aws::Inspector2::Model; using namespace Aws::Utils::Json; using namespace Aws::Utils; using namespace Aws; BatchUpdateMemberEc2DeepInspectionStatusResult::BatchUpdateMemberEc2DeepInspectionStatusResult() { } BatchUpdateMemberEc2DeepInspectionStatusResult::BatchUpdateMemberEc2DeepInspectionStatusResult(const Aws::AmazonWebServiceResult& result) { *this = result; } BatchUpdateMemberEc2DeepInspectionStatusResult& BatchUpdateMemberEc2DeepInspectionStatusResult::operator =(const Aws::AmazonWebServiceResult& result) { JsonView jsonValue = result.GetPayload().View(); if(jsonValue.ValueExists("accountIds")) { Aws::Utils::Array accountIdsJsonList = jsonValue.GetArray("accountIds"); for(unsigned accountIdsIndex = 0; accountIdsIndex < accountIdsJsonList.GetLength(); ++accountIdsIndex) { m_accountIds.push_back(accountIdsJsonList[accountIdsIndex].AsObject()); } } if(jsonValue.ValueExists("failedAccountIds")) { Aws::Utils::Array failedAccountIdsJsonList = jsonValue.GetArray("failedAccountIds"); for(unsigned failedAccountIdsIndex = 0; failedAccountIdsIndex < failedAccountIdsJsonList.GetLength(); ++failedAccountIdsIndex) { m_failedAccountIds.push_back(failedAccountIdsJsonList[failedAccountIdsIndex].AsObject()); } } const auto& headers = result.GetHeaderValueCollection(); const auto& requestIdIter = headers.find("x-amzn-requestid"); if(requestIdIter != headers.end()) { m_requestId = requestIdIter->second; } return *this; }