{-# LANGUAGE DeriveGeneric #-} {-# LANGUAGE DuplicateRecordFields #-} {-# LANGUAGE NamedFieldPuns #-} {-# LANGUAGE OverloadedStrings #-} {-# LANGUAGE RecordWildCards #-} {-# LANGUAGE StrictData #-} {-# LANGUAGE NoImplicitPrelude #-} {-# OPTIONS_GHC -fno-warn-unused-imports #-} {-# OPTIONS_GHC -fno-warn-unused-matches #-} -- Derived from AWS service descriptions, licensed under Apache 2.0. -- | -- Module : Amazonka.EC2.Types.GpuDeviceMemoryInfo -- Copyright : (c) 2013-2023 Brendan Hay -- License : Mozilla Public License, v. 2.0. -- Maintainer : Brendan Hay -- Stability : auto-generated -- Portability : non-portable (GHC extensions) module Amazonka.EC2.Types.GpuDeviceMemoryInfo where import qualified Amazonka.Core as Core import qualified Amazonka.Core.Lens.Internal as Lens import qualified Amazonka.Data as Data import Amazonka.EC2.Internal import qualified Amazonka.Prelude as Prelude -- | Describes the memory available to the GPU accelerator. -- -- /See:/ 'newGpuDeviceMemoryInfo' smart constructor. data GpuDeviceMemoryInfo = GpuDeviceMemoryInfo' { -- | The size of the memory available to the GPU accelerator, in MiB. sizeInMiB :: Prelude.Maybe Prelude.Int } deriving (Prelude.Eq, Prelude.Read, Prelude.Show, Prelude.Generic) -- | -- Create a value of 'GpuDeviceMemoryInfo' with all optional fields omitted. -- -- Use or to modify other optional fields. -- -- The following record fields are available, with the corresponding lenses provided -- for backwards compatibility: -- -- 'sizeInMiB', 'gpuDeviceMemoryInfo_sizeInMiB' - The size of the memory available to the GPU accelerator, in MiB. newGpuDeviceMemoryInfo :: GpuDeviceMemoryInfo newGpuDeviceMemoryInfo = GpuDeviceMemoryInfo' {sizeInMiB = Prelude.Nothing} -- | The size of the memory available to the GPU accelerator, in MiB. gpuDeviceMemoryInfo_sizeInMiB :: Lens.Lens' GpuDeviceMemoryInfo (Prelude.Maybe Prelude.Int) gpuDeviceMemoryInfo_sizeInMiB = Lens.lens (\GpuDeviceMemoryInfo' {sizeInMiB} -> sizeInMiB) (\s@GpuDeviceMemoryInfo' {} a -> s {sizeInMiB = a} :: GpuDeviceMemoryInfo) instance Data.FromXML GpuDeviceMemoryInfo where parseXML x = GpuDeviceMemoryInfo' Prelude.<$> (x Data..@? "sizeInMiB") instance Prelude.Hashable GpuDeviceMemoryInfo where hashWithSalt _salt GpuDeviceMemoryInfo' {..} = _salt `Prelude.hashWithSalt` sizeInMiB instance Prelude.NFData GpuDeviceMemoryInfo where rnf GpuDeviceMemoryInfo' {..} = Prelude.rnf sizeInMiB