# Copyright 2019 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
#     http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

# NOTE: This file is auto generated by the elixir code generator program.
# Do not edit this file manually.

defmodule GoogleApi.VMMigration.V1.Model.VmwareVmDetails do
  @moduledoc """
  VmwareVmDetails describes a VM in vCenter.

  ## Attributes

  *   `architecture` (*type:* `String.t`, *default:* `nil`) - Output only. The CPU architecture.
  *   `bootOption` (*type:* `String.t`, *default:* `nil`) - Output only. The VM Boot Option.
  *   `committedStorageMb` (*type:* `String.t`, *default:* `nil`) - The total size of the storage allocated to the VM in MB.
  *   `cpuCount` (*type:* `integer()`, *default:* `nil`) - The number of cpus in the VM.
  *   `datacenterDescription` (*type:* `String.t`, *default:* `nil`) - The descriptive name of the vCenter's datacenter this VM is contained in.
  *   `datacenterId` (*type:* `String.t`, *default:* `nil`) - The id of the vCenter's datacenter this VM is contained in.
  *   `diskCount` (*type:* `integer()`, *default:* `nil`) - The number of disks the VM has.
  *   `displayName` (*type:* `String.t`, *default:* `nil`) - The display name of the VM. Note that this is not necessarily unique.
  *   `guestDescription` (*type:* `String.t`, *default:* `nil`) - The VM's OS. See for example https://vdc-repo.vmware.com/vmwb-repository/dcr-public/da47f910-60ac-438b-8b9b-6122f4d14524/16b7274a-bf8b-4b4c-a05e-746f2aa93c8c/doc/vim.vm.GuestOsDescriptor.GuestOsIdentifier.html for types of strings this might hold.
  *   `memoryMb` (*type:* `integer()`, *default:* `nil`) - The size of the memory of the VM in MB.
  *   `powerState` (*type:* `String.t`, *default:* `nil`) - The power state of the VM at the moment list was taken.
  *   `uuid` (*type:* `String.t`, *default:* `nil`) - The unique identifier of the VM in vCenter.
  *   `vmId` (*type:* `String.t`, *default:* `nil`) - The VM's id in the source (note that this is not the MigratingVm's id). This is the moref id of the VM.
  """

  use GoogleApi.Gax.ModelBase

  @type t :: %__MODULE__{
          :architecture => String.t() | nil,
          :bootOption => String.t() | nil,
          :committedStorageMb => String.t() | nil,
          :cpuCount => integer() | nil,
          :datacenterDescription => String.t() | nil,
          :datacenterId => String.t() | nil,
          :diskCount => integer() | nil,
          :displayName => String.t() | nil,
          :guestDescription => String.t() | nil,
          :memoryMb => integer() | nil,
          :powerState => String.t() | nil,
          :uuid => String.t() | nil,
          :vmId => String.t() | nil
        }

  field(:architecture)
  field(:bootOption)
  field(:committedStorageMb)
  field(:cpuCount)
  field(:datacenterDescription)
  field(:datacenterId)
  field(:diskCount)
  field(:displayName)
  field(:guestDescription)
  field(:memoryMb)
  field(:powerState)
  field(:uuid)
  field(:vmId)
end

defimpl Poison.Decoder, for: GoogleApi.VMMigration.V1.Model.VmwareVmDetails do
  def decode(value, options) do
    GoogleApi.VMMigration.V1.Model.VmwareVmDetails.decode(value, options)
  end
end

defimpl Poison.Encoder, for: GoogleApi.VMMigration.V1.Model.VmwareVmDetails do
  def encode(value, options) do
    GoogleApi.Gax.ModelBase.encode(value, options)
  end
end
