62 lines
1.3 KiB
C++
62 lines
1.3 KiB
C++
|
|
/**
|
|||
|
|
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|||
|
|
* SPDX-License-Identifier: Apache-2.0.
|
|||
|
|
*/
|
|||
|
|
|
|||
|
|
#include <aws/elasticfilesystem/model/CreateMountTargetRequest.h>
|
|||
|
|
#include <aws/core/utils/json/JsonSerializer.h>
|
|||
|
|
|
|||
|
|
#include <utility>
|
|||
|
|
|
|||
|
|
using namespace Aws::EFS::Model;
|
|||
|
|
using namespace Aws::Utils::Json;
|
|||
|
|
using namespace Aws::Utils;
|
|||
|
|
|
|||
|
|
CreateMountTargetRequest::CreateMountTargetRequest() :
|
|||
|
|
m_fileSystemIdHasBeenSet(false),
|
|||
|
|
m_subnetIdHasBeenSet(false),
|
|||
|
|
m_ipAddressHasBeenSet(false),
|
|||
|
|
m_securityGroupsHasBeenSet(false)
|
|||
|
|
{
|
|||
|
|
}
|
|||
|
|
|
|||
|
|
Aws::String CreateMountTargetRequest::SerializePayload() const
|
|||
|
|
{
|
|||
|
|
JsonValue payload;
|
|||
|
|
|
|||
|
|
if(m_fileSystemIdHasBeenSet)
|
|||
|
|
{
|
|||
|
|
payload.WithString("FileSystemId", m_fileSystemId);
|
|||
|
|
|
|||
|
|
}
|
|||
|
|
|
|||
|
|
if(m_subnetIdHasBeenSet)
|
|||
|
|
{
|
|||
|
|
payload.WithString("SubnetId", m_subnetId);
|
|||
|
|
|
|||
|
|
}
|
|||
|
|
|
|||
|
|
if(m_ipAddressHasBeenSet)
|
|||
|
|
{
|
|||
|
|
payload.WithString("IpAddress", m_ipAddress);
|
|||
|
|
|
|||
|
|
}
|
|||
|
|
|
|||
|
|
if(m_securityGroupsHasBeenSet)
|
|||
|
|
{
|
|||
|
|
Array<JsonValue> securityGroupsJsonList(m_securityGroups.size());
|
|||
|
|
for(unsigned securityGroupsIndex = 0; securityGroupsIndex < securityGroupsJsonList.GetLength(); ++securityGroupsIndex)
|
|||
|
|
{
|
|||
|
|
securityGroupsJsonList[securityGroupsIndex].AsString(m_securityGroups[securityGroupsIndex]);
|
|||
|
|
}
|
|||
|
|
payload.WithArray("SecurityGroups", std::move(securityGroupsJsonList));
|
|||
|
|
|
|||
|
|
}
|
|||
|
|
|
|||
|
|
return payload.View().WriteReadable();
|
|||
|
|
}
|
|||
|
|
|
|||
|
|
|
|||
|
|
|
|||
|
|
|