# NOTE: This file is auto generated by OpenAPI Generator 7.0.1 (https://openapi-generator.tech).
# Do not edit this file manually.

defmodule DockerEngineAPI.Model.Network do
  @moduledoc """
  
  """

  @derive Jason.Encoder
  defstruct [
    :Name,
    :Id,
    :Created,
    :Scope,
    :Driver,
    :EnableIPv6,
    :IPAM,
    :Internal,
    :Attachable,
    :Ingress,
    :Containers,
    :Options,
    :Labels
  ]

  @type t :: %__MODULE__{
    :Name => String.t | nil,
    :Id => String.t | nil,
    :Created => String.t | nil,
    :Scope => String.t | nil,
    :Driver => String.t | nil,
    :EnableIPv6 => boolean() | nil,
    :IPAM => DockerEngineAPI.Model.Ipam.t | nil,
    :Internal => boolean() | nil,
    :Attachable => boolean() | nil,
    :Ingress => boolean() | nil,
    :Containers => %{optional(String.t) => DockerEngineAPI.Model.NetworkContainer.t} | nil,
    :Options => %{optional(String.t) => String.t} | nil,
    :Labels => %{optional(String.t) => String.t} | nil
  }

  alias DockerEngineAPI.Deserializer

  def decode(value) do
    value
     |> Deserializer.deserialize(:IPAM, :struct, DockerEngineAPI.Model.Ipam)
     |> Deserializer.deserialize(:Containers, :map, DockerEngineAPI.Model.NetworkContainer)
  end
end

