# 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.HealthCare.V1beta1.Model.Action do
  @moduledoc """
  Specifies a selection of tags and an `Action` to apply to each one.

  ## Attributes

  *   `cleanImageTag` (*type:* `GoogleApi.HealthCare.V1beta1.Model.ImageConfig.t`, *default:* `nil`) - Inspect image and transform sensitive burnt-in text. Doesn't apply to elements nested in a sequence, which revert to `Keep`. Supported [tags](http://dicom.nema.org/medical/dicom/2018e/output/chtml/part06/chapter_6.html): PixelData
  *   `cleanTextTag` (*type:* `GoogleApi.HealthCare.V1beta1.Model.CleanTextTag.t`, *default:* `nil`) - Inspect text and transform sensitive text. Configurable via TextConfig. Supported Value Representations: AE, LO, LT, PN, SH, ST, UC, UT, DA, DT, AS
  *   `deleteTag` (*type:* `GoogleApi.HealthCare.V1beta1.Model.DeleteTag.t`, *default:* `nil`) - Delete tag.
  *   `keepTag` (*type:* `GoogleApi.HealthCare.V1beta1.Model.KeepTag.t`, *default:* `nil`) - Keep tag unchanged.
  *   `queries` (*type:* `list(String.t)`, *default:* `nil`) - Select all tags with the listed tag IDs, names, or Value Representations (VRs). Examples: ID: "00100010" Keyword: "PatientName" VR: "PN"
  *   `recurseTag` (*type:* `GoogleApi.HealthCare.V1beta1.Model.RecurseTag.t`, *default:* `nil`) - Recursively apply DICOM de-id to tags nested in a sequence. Supported [Value Representation] (http://dicom.nema.org/medical/dicom/2018e/output/chtml/part05/sect_6.2.html#table_6.2-1): SQ
  *   `regenUidTag` (*type:* `GoogleApi.HealthCare.V1beta1.Model.RegenUidTag.t`, *default:* `nil`) - Replace UID with a new generated UID. Supported [Value Representation] (http://dicom.nema.org/medical/dicom/2018e/output/chtml/part05/sect_6.2.html#table_6.2-1): UI
  *   `removeTag` (*type:* `GoogleApi.HealthCare.V1beta1.Model.RemoveTag.t`, *default:* `nil`) - Replace with empty tag.
  *   `resetTag` (*type:* `GoogleApi.HealthCare.V1beta1.Model.ResetTag.t`, *default:* `nil`) - Reset tag to a placeholder value.
  """

  use GoogleApi.Gax.ModelBase

  @type t :: %__MODULE__{
          :cleanImageTag => GoogleApi.HealthCare.V1beta1.Model.ImageConfig.t() | nil,
          :cleanTextTag => GoogleApi.HealthCare.V1beta1.Model.CleanTextTag.t() | nil,
          :deleteTag => GoogleApi.HealthCare.V1beta1.Model.DeleteTag.t() | nil,
          :keepTag => GoogleApi.HealthCare.V1beta1.Model.KeepTag.t() | nil,
          :queries => list(String.t()) | nil,
          :recurseTag => GoogleApi.HealthCare.V1beta1.Model.RecurseTag.t() | nil,
          :regenUidTag => GoogleApi.HealthCare.V1beta1.Model.RegenUidTag.t() | nil,
          :removeTag => GoogleApi.HealthCare.V1beta1.Model.RemoveTag.t() | nil,
          :resetTag => GoogleApi.HealthCare.V1beta1.Model.ResetTag.t() | nil
        }

  field(:cleanImageTag, as: GoogleApi.HealthCare.V1beta1.Model.ImageConfig)
  field(:cleanTextTag, as: GoogleApi.HealthCare.V1beta1.Model.CleanTextTag)
  field(:deleteTag, as: GoogleApi.HealthCare.V1beta1.Model.DeleteTag)
  field(:keepTag, as: GoogleApi.HealthCare.V1beta1.Model.KeepTag)
  field(:queries, type: :list)
  field(:recurseTag, as: GoogleApi.HealthCare.V1beta1.Model.RecurseTag)
  field(:regenUidTag, as: GoogleApi.HealthCare.V1beta1.Model.RegenUidTag)
  field(:removeTag, as: GoogleApi.HealthCare.V1beta1.Model.RemoveTag)
  field(:resetTag, as: GoogleApi.HealthCare.V1beta1.Model.ResetTag)
end

defimpl Poison.Decoder, for: GoogleApi.HealthCare.V1beta1.Model.Action do
  def decode(value, options) do
    GoogleApi.HealthCare.V1beta1.Model.Action.decode(value, options)
  end
end

defimpl Poison.Encoder, for: GoogleApi.HealthCare.V1beta1.Model.Action do
  def encode(value, options) do
    GoogleApi.Gax.ModelBase.encode(value, options)
  end
end
