lib/google_api/content/v2/model/inventory_pickup.ex

# 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.Content.V2.Model.InventoryPickup do
  @moduledoc """


  ## Attributes

  *   `pickupMethod` (*type:* `String.t`, *default:* `nil`) - Whether store pickup is available for this offer and whether the pickup option should be shown as buy, reserve, or not supported. Only supported for local inventory. Unless the value is "not supported", must be submitted together with `pickupSla`. Acceptable values are: - "`buy`" - "`not supported`" - "`reserve`" - "`ship to store`" 
  *   `pickupSla` (*type:* `String.t`, *default:* `nil`) - The expected date that an order will be ready for pickup, relative to when the order is placed. Only supported for local inventory. Must be submitted together with `pickupMethod`. Acceptable values are: - "`five day`" - "`four day`" - "`multi day`" - "`multi week`" - "`next day`" - "`same day`" - "`seven day`" - "`six day`" - "`three day`" - "`two day`" 
  """

  use GoogleApi.Gax.ModelBase

  @type t :: %__MODULE__{
          :pickupMethod => String.t() | nil,
          :pickupSla => String.t() | nil
        }

  field(:pickupMethod)
  field(:pickupSla)
end

defimpl Poison.Decoder, for: GoogleApi.Content.V2.Model.InventoryPickup do
  def decode(value, options) do
    GoogleApi.Content.V2.Model.InventoryPickup.decode(value, options)
  end
end

defimpl Poison.Encoder, for: GoogleApi.Content.V2.Model.InventoryPickup do
  def encode(value, options) do
    GoogleApi.Gax.ModelBase.encode(value, options)
  end
end