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

Describes a block device mapping.

See Also:

AWS * API Reference

*/ class InstanceBlockDeviceMapping { public: AWS_EC2_API InstanceBlockDeviceMapping(); AWS_EC2_API InstanceBlockDeviceMapping(const Aws::Utils::Xml::XmlNode& xmlNode); AWS_EC2_API InstanceBlockDeviceMapping& operator=(const Aws::Utils::Xml::XmlNode& xmlNode); AWS_EC2_API void OutputToStream(Aws::OStream& ostream, const char* location, unsigned index, const char* locationValue) const; AWS_EC2_API void OutputToStream(Aws::OStream& oStream, const char* location) const; /** *

The device name (for example, /dev/sdh or * xvdh).

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

The device name (for example, /dev/sdh or * xvdh).

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

The device name (for example, /dev/sdh or * xvdh).

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

The device name (for example, /dev/sdh or * xvdh).

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

The device name (for example, /dev/sdh or * xvdh).

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

The device name (for example, /dev/sdh or * xvdh).

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

The device name (for example, /dev/sdh or * xvdh).

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

The device name (for example, /dev/sdh or * xvdh).

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

Parameters used to automatically set up EBS volumes when the instance is * launched.

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

Parameters used to automatically set up EBS volumes when the instance is * launched.

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

Parameters used to automatically set up EBS volumes when the instance is * launched.

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

Parameters used to automatically set up EBS volumes when the instance is * launched.

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

Parameters used to automatically set up EBS volumes when the instance is * launched.

*/ inline InstanceBlockDeviceMapping& WithEbs(const EbsInstanceBlockDevice& value) { SetEbs(value); return *this;} /** *

Parameters used to automatically set up EBS volumes when the instance is * launched.

*/ inline InstanceBlockDeviceMapping& WithEbs(EbsInstanceBlockDevice&& value) { SetEbs(std::move(value)); return *this;} private: Aws::String m_deviceName; bool m_deviceNameHasBeenSet = false; EbsInstanceBlockDevice m_ebs; bool m_ebsHasBeenSet = false; }; } // namespace Model } // namespace EC2 } // namespace Aws