/** * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. * SPDX-License-Identifier: Apache-2.0. */ #pragma once #include #include #include #include namespace Aws { namespace Utils { namespace Json { class JsonValue; class JsonView; } // namespace Json } // namespace Utils namespace OpsWorks { namespace Model { /** *

Describes a block device mapping. This data type maps directly to the Amazon * EC2 BlockDeviceMapping * data type.

See Also:

AWS * API Reference

*/ class BlockDeviceMapping { public: AWS_OPSWORKS_API BlockDeviceMapping(); AWS_OPSWORKS_API BlockDeviceMapping(Aws::Utils::Json::JsonView jsonValue); AWS_OPSWORKS_API BlockDeviceMapping& operator=(Aws::Utils::Json::JsonView jsonValue); AWS_OPSWORKS_API Aws::Utils::Json::JsonValue Jsonize() const; /** *

The device name that is exposed to the instance, such as * /dev/sdh. For the root device, you can use the explicit device name * or you can set this parameter to ROOT_DEVICE and AWS OpsWorks * Stacks will provide the correct device name.

*/ inline const Aws::String& GetDeviceName() const{ return m_deviceName; } /** *

The device name that is exposed to the instance, such as * /dev/sdh. For the root device, you can use the explicit device name * or you can set this parameter to ROOT_DEVICE and AWS OpsWorks * Stacks will provide the correct device name.

*/ inline bool DeviceNameHasBeenSet() const { return m_deviceNameHasBeenSet; } /** *

The device name that is exposed to the instance, such as * /dev/sdh. For the root device, you can use the explicit device name * or you can set this parameter to ROOT_DEVICE and AWS OpsWorks * Stacks will provide the correct device name.

*/ inline void SetDeviceName(const Aws::String& value) { m_deviceNameHasBeenSet = true; m_deviceName = value; } /** *

The device name that is exposed to the instance, such as * /dev/sdh. For the root device, you can use the explicit device name * or you can set this parameter to ROOT_DEVICE and AWS OpsWorks * Stacks will provide the correct device name.

*/ inline void SetDeviceName(Aws::String&& value) { m_deviceNameHasBeenSet = true; m_deviceName = std::move(value); } /** *

The device name that is exposed to the instance, such as * /dev/sdh. For the root device, you can use the explicit device name * or you can set this parameter to ROOT_DEVICE and AWS OpsWorks * Stacks will provide the correct device name.

*/ inline void SetDeviceName(const char* value) { m_deviceNameHasBeenSet = true; m_deviceName.assign(value); } /** *

The device name that is exposed to the instance, such as * /dev/sdh. For the root device, you can use the explicit device name * or you can set this parameter to ROOT_DEVICE and AWS OpsWorks * Stacks will provide the correct device name.

*/ inline BlockDeviceMapping& WithDeviceName(const Aws::String& value) { SetDeviceName(value); return *this;} /** *

The device name that is exposed to the instance, such as * /dev/sdh. For the root device, you can use the explicit device name * or you can set this parameter to ROOT_DEVICE and AWS OpsWorks * Stacks will provide the correct device name.

*/ inline BlockDeviceMapping& WithDeviceName(Aws::String&& value) { SetDeviceName(std::move(value)); return *this;} /** *

The device name that is exposed to the instance, such as * /dev/sdh. For the root device, you can use the explicit device name * or you can set this parameter to ROOT_DEVICE and AWS OpsWorks * Stacks will provide the correct device name.

*/ inline BlockDeviceMapping& WithDeviceName(const char* value) { SetDeviceName(value); return *this;} /** *

Suppresses the specified device included in the AMI's block device * mapping.

*/ inline const Aws::String& GetNoDevice() const{ return m_noDevice; } /** *

Suppresses the specified device included in the AMI's block device * mapping.

*/ inline bool NoDeviceHasBeenSet() const { return m_noDeviceHasBeenSet; } /** *

Suppresses the specified device included in the AMI's block device * mapping.

*/ inline void SetNoDevice(const Aws::String& value) { m_noDeviceHasBeenSet = true; m_noDevice = value; } /** *

Suppresses the specified device included in the AMI's block device * mapping.

*/ inline void SetNoDevice(Aws::String&& value) { m_noDeviceHasBeenSet = true; m_noDevice = std::move(value); } /** *

Suppresses the specified device included in the AMI's block device * mapping.

*/ inline void SetNoDevice(const char* value) { m_noDeviceHasBeenSet = true; m_noDevice.assign(value); } /** *

Suppresses the specified device included in the AMI's block device * mapping.

*/ inline BlockDeviceMapping& WithNoDevice(const Aws::String& value) { SetNoDevice(value); return *this;} /** *

Suppresses the specified device included in the AMI's block device * mapping.

*/ inline BlockDeviceMapping& WithNoDevice(Aws::String&& value) { SetNoDevice(std::move(value)); return *this;} /** *

Suppresses the specified device included in the AMI's block device * mapping.

*/ inline BlockDeviceMapping& WithNoDevice(const char* value) { SetNoDevice(value); return *this;} /** *

The virtual device name. For more information, see BlockDeviceMapping.

*/ inline const Aws::String& GetVirtualName() const{ return m_virtualName; } /** *

The virtual device name. For more information, see BlockDeviceMapping.

*/ inline bool VirtualNameHasBeenSet() const { return m_virtualNameHasBeenSet; } /** *

The virtual device name. For more information, see BlockDeviceMapping.

*/ inline void SetVirtualName(const Aws::String& value) { m_virtualNameHasBeenSet = true; m_virtualName = value; } /** *

The virtual device name. For more information, see BlockDeviceMapping.

*/ inline void SetVirtualName(Aws::String&& value) { m_virtualNameHasBeenSet = true; m_virtualName = std::move(value); } /** *

The virtual device name. For more information, see BlockDeviceMapping.

*/ inline void SetVirtualName(const char* value) { m_virtualNameHasBeenSet = true; m_virtualName.assign(value); } /** *

The virtual device name. For more information, see BlockDeviceMapping.

*/ inline BlockDeviceMapping& WithVirtualName(const Aws::String& value) { SetVirtualName(value); return *this;} /** *

The virtual device name. For more information, see BlockDeviceMapping.

*/ inline BlockDeviceMapping& WithVirtualName(Aws::String&& value) { SetVirtualName(std::move(value)); return *this;} /** *

The virtual device name. For more information, see BlockDeviceMapping.

*/ inline BlockDeviceMapping& WithVirtualName(const char* value) { SetVirtualName(value); return *this;} /** *

An EBSBlockDevice that defines how to configure an Amazon EBS * volume when the instance is launched.

*/ inline const EbsBlockDevice& GetEbs() const{ return m_ebs; } /** *

An EBSBlockDevice that defines how to configure an Amazon EBS * volume when the instance is launched.

*/ inline bool EbsHasBeenSet() const { return m_ebsHasBeenSet; } /** *

An EBSBlockDevice that defines how to configure an Amazon EBS * volume when the instance is launched.

*/ inline void SetEbs(const EbsBlockDevice& value) { m_ebsHasBeenSet = true; m_ebs = value; } /** *

An EBSBlockDevice that defines how to configure an Amazon EBS * volume when the instance is launched.

*/ inline void SetEbs(EbsBlockDevice&& value) { m_ebsHasBeenSet = true; m_ebs = std::move(value); } /** *

An EBSBlockDevice that defines how to configure an Amazon EBS * volume when the instance is launched.

*/ inline BlockDeviceMapping& WithEbs(const EbsBlockDevice& value) { SetEbs(value); return *this;} /** *

An EBSBlockDevice that defines how to configure an Amazon EBS * volume when the instance is launched.

*/ inline BlockDeviceMapping& WithEbs(EbsBlockDevice&& value) { SetEbs(std::move(value)); return *this;} private: Aws::String m_deviceName; bool m_deviceNameHasBeenSet = false; Aws::String m_noDevice; bool m_noDeviceHasBeenSet = false; Aws::String m_virtualName; bool m_virtualNameHasBeenSet = false; EbsBlockDevice m_ebs; bool m_ebsHasBeenSet = false; }; } // namespace Model } // namespace OpsWorks } // namespace Aws