/** * 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 Lightsail { namespace Model { /** *

Describes the hardware for the instance.

See Also:

AWS * API Reference

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

The number of vCPUs the instance has.

*/ inline int GetCpuCount() const{ return m_cpuCount; } /** *

The number of vCPUs the instance has.

*/ inline bool CpuCountHasBeenSet() const { return m_cpuCountHasBeenSet; } /** *

The number of vCPUs the instance has.

*/ inline void SetCpuCount(int value) { m_cpuCountHasBeenSet = true; m_cpuCount = value; } /** *

The number of vCPUs the instance has.

*/ inline InstanceHardware& WithCpuCount(int value) { SetCpuCount(value); return *this;} /** *

The disks attached to the instance.

*/ inline const Aws::Vector& GetDisks() const{ return m_disks; } /** *

The disks attached to the instance.

*/ inline bool DisksHasBeenSet() const { return m_disksHasBeenSet; } /** *

The disks attached to the instance.

*/ inline void SetDisks(const Aws::Vector& value) { m_disksHasBeenSet = true; m_disks = value; } /** *

The disks attached to the instance.

*/ inline void SetDisks(Aws::Vector&& value) { m_disksHasBeenSet = true; m_disks = std::move(value); } /** *

The disks attached to the instance.

*/ inline InstanceHardware& WithDisks(const Aws::Vector& value) { SetDisks(value); return *this;} /** *

The disks attached to the instance.

*/ inline InstanceHardware& WithDisks(Aws::Vector&& value) { SetDisks(std::move(value)); return *this;} /** *

The disks attached to the instance.

*/ inline InstanceHardware& AddDisks(const Disk& value) { m_disksHasBeenSet = true; m_disks.push_back(value); return *this; } /** *

The disks attached to the instance.

*/ inline InstanceHardware& AddDisks(Disk&& value) { m_disksHasBeenSet = true; m_disks.push_back(std::move(value)); return *this; } /** *

The amount of RAM in GB on the instance (e.g., 1.0).

*/ inline double GetRamSizeInGb() const{ return m_ramSizeInGb; } /** *

The amount of RAM in GB on the instance (e.g., 1.0).

*/ inline bool RamSizeInGbHasBeenSet() const { return m_ramSizeInGbHasBeenSet; } /** *

The amount of RAM in GB on the instance (e.g., 1.0).

*/ inline void SetRamSizeInGb(double value) { m_ramSizeInGbHasBeenSet = true; m_ramSizeInGb = value; } /** *

The amount of RAM in GB on the instance (e.g., 1.0).

*/ inline InstanceHardware& WithRamSizeInGb(double value) { SetRamSizeInGb(value); return *this;} private: int m_cpuCount; bool m_cpuCountHasBeenSet = false; Aws::Vector m_disks; bool m_disksHasBeenSet = false; double m_ramSizeInGb; bool m_ramSizeInGbHasBeenSet = false; }; } // namespace Model } // namespace Lightsail } // namespace Aws