{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE DuplicateRecordFields #-}
{-# LANGUAGE NamedFieldPuns #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE StrictData #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# OPTIONS_GHC -fno-warn-unused-binds #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-unused-matches #-}

-- Derived from AWS service descriptions, licensed under Apache 2.0.

-- |
-- Module      : Amazonka.LakeFormation.UpdateLFTag
-- Copyright   : (c) 2013-2021 Brendan Hay
-- License     : Mozilla Public License, v. 2.0.
-- Maintainer  : Brendan Hay <brendan.g.hay+amazonka@gmail.com>
-- Stability   : auto-generated
-- Portability : non-portable (GHC extensions)
--
-- Updates the list of possible values for the specified tag key. If the
-- tag does not exist, the operation throws an EntityNotFoundException. The
-- values in the delete key values will be deleted from list of possible
-- values. If any value in the delete key values is attached to a resource,
-- then API errors out with a 400 Exception - \"Update not allowed\". Untag
-- the attribute before deleting the tag key\'s value.
module Amazonka.LakeFormation.UpdateLFTag
  ( -- * Creating a Request
    UpdateLFTag (..),
    newUpdateLFTag,

    -- * Request Lenses
    updateLFTag_catalogId,
    updateLFTag_tagValuesToAdd,
    updateLFTag_tagValuesToDelete,
    updateLFTag_tagKey,

    -- * Destructuring the Response
    UpdateLFTagResponse (..),
    newUpdateLFTagResponse,

    -- * Response Lenses
    updateLFTagResponse_httpStatus,
  )
where

import qualified Amazonka.Core as Core
import Amazonka.LakeFormation.Types
import qualified Amazonka.Lens as Lens
import qualified Amazonka.Prelude as Prelude
import qualified Amazonka.Request as Request
import qualified Amazonka.Response as Response

-- | /See:/ 'newUpdateLFTag' smart constructor.
data UpdateLFTag = UpdateLFTag'
  { -- | The identifier for the Data Catalog. By default, the account ID. The
    -- Data Catalog is the persistent metadata store. It contains database
    -- definitions, table definitions, and other control information to manage
    -- your AWS Lake Formation environment.
    UpdateLFTag -> Maybe Text
catalogId :: Prelude.Maybe Prelude.Text,
    -- | A list of tag values to add from the tag.
    UpdateLFTag -> Maybe (NonEmpty Text)
tagValuesToAdd :: Prelude.Maybe (Prelude.NonEmpty Prelude.Text),
    -- | A list of tag values to delete from the tag.
    UpdateLFTag -> Maybe (NonEmpty Text)
tagValuesToDelete :: Prelude.Maybe (Prelude.NonEmpty Prelude.Text),
    -- | The key-name for the tag for which to add or delete values.
    UpdateLFTag -> Text
tagKey :: Prelude.Text
  }
  deriving (UpdateLFTag -> UpdateLFTag -> Bool
(UpdateLFTag -> UpdateLFTag -> Bool)
-> (UpdateLFTag -> UpdateLFTag -> Bool) -> Eq UpdateLFTag
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: UpdateLFTag -> UpdateLFTag -> Bool
$c/= :: UpdateLFTag -> UpdateLFTag -> Bool
== :: UpdateLFTag -> UpdateLFTag -> Bool
$c== :: UpdateLFTag -> UpdateLFTag -> Bool
Prelude.Eq, ReadPrec [UpdateLFTag]
ReadPrec UpdateLFTag
Int -> ReadS UpdateLFTag
ReadS [UpdateLFTag]
(Int -> ReadS UpdateLFTag)
-> ReadS [UpdateLFTag]
-> ReadPrec UpdateLFTag
-> ReadPrec [UpdateLFTag]
-> Read UpdateLFTag
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [UpdateLFTag]
$creadListPrec :: ReadPrec [UpdateLFTag]
readPrec :: ReadPrec UpdateLFTag
$creadPrec :: ReadPrec UpdateLFTag
readList :: ReadS [UpdateLFTag]
$creadList :: ReadS [UpdateLFTag]
readsPrec :: Int -> ReadS UpdateLFTag
$creadsPrec :: Int -> ReadS UpdateLFTag
Prelude.Read, Int -> UpdateLFTag -> ShowS
[UpdateLFTag] -> ShowS
UpdateLFTag -> String
(Int -> UpdateLFTag -> ShowS)
-> (UpdateLFTag -> String)
-> ([UpdateLFTag] -> ShowS)
-> Show UpdateLFTag
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [UpdateLFTag] -> ShowS
$cshowList :: [UpdateLFTag] -> ShowS
show :: UpdateLFTag -> String
$cshow :: UpdateLFTag -> String
showsPrec :: Int -> UpdateLFTag -> ShowS
$cshowsPrec :: Int -> UpdateLFTag -> ShowS
Prelude.Show, (forall x. UpdateLFTag -> Rep UpdateLFTag x)
-> (forall x. Rep UpdateLFTag x -> UpdateLFTag)
-> Generic UpdateLFTag
forall x. Rep UpdateLFTag x -> UpdateLFTag
forall x. UpdateLFTag -> Rep UpdateLFTag x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep UpdateLFTag x -> UpdateLFTag
$cfrom :: forall x. UpdateLFTag -> Rep UpdateLFTag x
Prelude.Generic)

-- |
-- Create a value of 'UpdateLFTag' with all optional fields omitted.
--
-- Use <https://hackage.haskell.org/package/generic-lens generic-lens> or <https://hackage.haskell.org/package/optics optics> to modify other optional fields.
--
-- The following record fields are available, with the corresponding lenses provided
-- for backwards compatibility:
--
-- 'catalogId', 'updateLFTag_catalogId' - The identifier for the Data Catalog. By default, the account ID. The
-- Data Catalog is the persistent metadata store. It contains database
-- definitions, table definitions, and other control information to manage
-- your AWS Lake Formation environment.
--
-- 'tagValuesToAdd', 'updateLFTag_tagValuesToAdd' - A list of tag values to add from the tag.
--
-- 'tagValuesToDelete', 'updateLFTag_tagValuesToDelete' - A list of tag values to delete from the tag.
--
-- 'tagKey', 'updateLFTag_tagKey' - The key-name for the tag for which to add or delete values.
newUpdateLFTag ::
  -- | 'tagKey'
  Prelude.Text ->
  UpdateLFTag
newUpdateLFTag :: Text -> UpdateLFTag
newUpdateLFTag Text
pTagKey_ =
  UpdateLFTag' :: Maybe Text
-> Maybe (NonEmpty Text)
-> Maybe (NonEmpty Text)
-> Text
-> UpdateLFTag
UpdateLFTag'
    { $sel:catalogId:UpdateLFTag' :: Maybe Text
catalogId = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:tagValuesToAdd:UpdateLFTag' :: Maybe (NonEmpty Text)
tagValuesToAdd = Maybe (NonEmpty Text)
forall a. Maybe a
Prelude.Nothing,
      $sel:tagValuesToDelete:UpdateLFTag' :: Maybe (NonEmpty Text)
tagValuesToDelete = Maybe (NonEmpty Text)
forall a. Maybe a
Prelude.Nothing,
      $sel:tagKey:UpdateLFTag' :: Text
tagKey = Text
pTagKey_
    }

-- | The identifier for the Data Catalog. By default, the account ID. The
-- Data Catalog is the persistent metadata store. It contains database
-- definitions, table definitions, and other control information to manage
-- your AWS Lake Formation environment.
updateLFTag_catalogId :: Lens.Lens' UpdateLFTag (Prelude.Maybe Prelude.Text)
updateLFTag_catalogId :: (Maybe Text -> f (Maybe Text)) -> UpdateLFTag -> f UpdateLFTag
updateLFTag_catalogId = (UpdateLFTag -> Maybe Text)
-> (UpdateLFTag -> Maybe Text -> UpdateLFTag)
-> Lens UpdateLFTag UpdateLFTag (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateLFTag' {Maybe Text
catalogId :: Maybe Text
$sel:catalogId:UpdateLFTag' :: UpdateLFTag -> Maybe Text
catalogId} -> Maybe Text
catalogId) (\s :: UpdateLFTag
s@UpdateLFTag' {} Maybe Text
a -> UpdateLFTag
s {$sel:catalogId:UpdateLFTag' :: Maybe Text
catalogId = Maybe Text
a} :: UpdateLFTag)

-- | A list of tag values to add from the tag.
updateLFTag_tagValuesToAdd :: Lens.Lens' UpdateLFTag (Prelude.Maybe (Prelude.NonEmpty Prelude.Text))
updateLFTag_tagValuesToAdd :: (Maybe (NonEmpty Text) -> f (Maybe (NonEmpty Text)))
-> UpdateLFTag -> f UpdateLFTag
updateLFTag_tagValuesToAdd = (UpdateLFTag -> Maybe (NonEmpty Text))
-> (UpdateLFTag -> Maybe (NonEmpty Text) -> UpdateLFTag)
-> Lens
     UpdateLFTag
     UpdateLFTag
     (Maybe (NonEmpty Text))
     (Maybe (NonEmpty Text))
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateLFTag' {Maybe (NonEmpty Text)
tagValuesToAdd :: Maybe (NonEmpty Text)
$sel:tagValuesToAdd:UpdateLFTag' :: UpdateLFTag -> Maybe (NonEmpty Text)
tagValuesToAdd} -> Maybe (NonEmpty Text)
tagValuesToAdd) (\s :: UpdateLFTag
s@UpdateLFTag' {} Maybe (NonEmpty Text)
a -> UpdateLFTag
s {$sel:tagValuesToAdd:UpdateLFTag' :: Maybe (NonEmpty Text)
tagValuesToAdd = Maybe (NonEmpty Text)
a} :: UpdateLFTag) ((Maybe (NonEmpty Text) -> f (Maybe (NonEmpty Text)))
 -> UpdateLFTag -> f UpdateLFTag)
-> ((Maybe (NonEmpty Text) -> f (Maybe (NonEmpty Text)))
    -> Maybe (NonEmpty Text) -> f (Maybe (NonEmpty Text)))
-> (Maybe (NonEmpty Text) -> f (Maybe (NonEmpty Text)))
-> UpdateLFTag
-> f UpdateLFTag
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso
  (NonEmpty Text) (NonEmpty Text) (NonEmpty Text) (NonEmpty Text)
-> Iso
     (Maybe (NonEmpty Text))
     (Maybe (NonEmpty Text))
     (Maybe (NonEmpty Text))
     (Maybe (NonEmpty Text))
forall (f :: * -> *) (g :: * -> *) s t a b.
(Functor f, Functor g) =>
AnIso s t a b -> Iso (f s) (g t) (f a) (g b)
Lens.mapping AnIso
  (NonEmpty Text) (NonEmpty Text) (NonEmpty Text) (NonEmpty Text)
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | A list of tag values to delete from the tag.
updateLFTag_tagValuesToDelete :: Lens.Lens' UpdateLFTag (Prelude.Maybe (Prelude.NonEmpty Prelude.Text))
updateLFTag_tagValuesToDelete :: (Maybe (NonEmpty Text) -> f (Maybe (NonEmpty Text)))
-> UpdateLFTag -> f UpdateLFTag
updateLFTag_tagValuesToDelete = (UpdateLFTag -> Maybe (NonEmpty Text))
-> (UpdateLFTag -> Maybe (NonEmpty Text) -> UpdateLFTag)
-> Lens
     UpdateLFTag
     UpdateLFTag
     (Maybe (NonEmpty Text))
     (Maybe (NonEmpty Text))
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateLFTag' {Maybe (NonEmpty Text)
tagValuesToDelete :: Maybe (NonEmpty Text)
$sel:tagValuesToDelete:UpdateLFTag' :: UpdateLFTag -> Maybe (NonEmpty Text)
tagValuesToDelete} -> Maybe (NonEmpty Text)
tagValuesToDelete) (\s :: UpdateLFTag
s@UpdateLFTag' {} Maybe (NonEmpty Text)
a -> UpdateLFTag
s {$sel:tagValuesToDelete:UpdateLFTag' :: Maybe (NonEmpty Text)
tagValuesToDelete = Maybe (NonEmpty Text)
a} :: UpdateLFTag) ((Maybe (NonEmpty Text) -> f (Maybe (NonEmpty Text)))
 -> UpdateLFTag -> f UpdateLFTag)
-> ((Maybe (NonEmpty Text) -> f (Maybe (NonEmpty Text)))
    -> Maybe (NonEmpty Text) -> f (Maybe (NonEmpty Text)))
-> (Maybe (NonEmpty Text) -> f (Maybe (NonEmpty Text)))
-> UpdateLFTag
-> f UpdateLFTag
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso
  (NonEmpty Text) (NonEmpty Text) (NonEmpty Text) (NonEmpty Text)
-> Iso
     (Maybe (NonEmpty Text))
     (Maybe (NonEmpty Text))
     (Maybe (NonEmpty Text))
     (Maybe (NonEmpty Text))
forall (f :: * -> *) (g :: * -> *) s t a b.
(Functor f, Functor g) =>
AnIso s t a b -> Iso (f s) (g t) (f a) (g b)
Lens.mapping AnIso
  (NonEmpty Text) (NonEmpty Text) (NonEmpty Text) (NonEmpty Text)
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | The key-name for the tag for which to add or delete values.
updateLFTag_tagKey :: Lens.Lens' UpdateLFTag Prelude.Text
updateLFTag_tagKey :: (Text -> f Text) -> UpdateLFTag -> f UpdateLFTag
updateLFTag_tagKey = (UpdateLFTag -> Text)
-> (UpdateLFTag -> Text -> UpdateLFTag)
-> Lens UpdateLFTag UpdateLFTag Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateLFTag' {Text
tagKey :: Text
$sel:tagKey:UpdateLFTag' :: UpdateLFTag -> Text
tagKey} -> Text
tagKey) (\s :: UpdateLFTag
s@UpdateLFTag' {} Text
a -> UpdateLFTag
s {$sel:tagKey:UpdateLFTag' :: Text
tagKey = Text
a} :: UpdateLFTag)

instance Core.AWSRequest UpdateLFTag where
  type AWSResponse UpdateLFTag = UpdateLFTagResponse
  request :: UpdateLFTag -> Request UpdateLFTag
request = Service -> UpdateLFTag -> Request UpdateLFTag
forall a. (ToRequest a, ToJSON a) => Service -> a -> Request a
Request.postJSON Service
defaultService
  response :: Logger
-> Service
-> Proxy UpdateLFTag
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse UpdateLFTag)))
response =
    (Int
 -> ResponseHeaders
 -> ()
 -> Either String (AWSResponse UpdateLFTag))
-> Logger
-> Service
-> Proxy UpdateLFTag
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse UpdateLFTag)))
forall (m :: * -> *) a.
MonadResource m =>
(Int -> ResponseHeaders -> () -> Either String (AWSResponse a))
-> Logger
-> Service
-> Proxy a
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse a)))
Response.receiveEmpty
      ( \Int
s ResponseHeaders
h ()
x ->
          Int -> UpdateLFTagResponse
UpdateLFTagResponse'
            (Int -> UpdateLFTagResponse)
-> Either String Int -> Either String UpdateLFTagResponse
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Int -> Either String Int
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure (Int -> Int
forall a. Enum a => a -> Int
Prelude.fromEnum Int
s))
      )

instance Prelude.Hashable UpdateLFTag

instance Prelude.NFData UpdateLFTag

instance Core.ToHeaders UpdateLFTag where
  toHeaders :: UpdateLFTag -> ResponseHeaders
toHeaders =
    ResponseHeaders -> UpdateLFTag -> ResponseHeaders
forall a b. a -> b -> a
Prelude.const
      ( [ResponseHeaders] -> ResponseHeaders
forall a. Monoid a => [a] -> a
Prelude.mconcat
          [ HeaderName
"X-Amz-Target"
              HeaderName -> ByteString -> ResponseHeaders
forall a. ToHeader a => HeaderName -> a -> ResponseHeaders
Core.=# ( ByteString
"AWSLakeFormation.UpdateLFTag" ::
                          Prelude.ByteString
                      ),
            HeaderName
"Content-Type"
              HeaderName -> ByteString -> ResponseHeaders
forall a. ToHeader a => HeaderName -> a -> ResponseHeaders
Core.=# ( ByteString
"application/x-amz-json-1.1" ::
                          Prelude.ByteString
                      )
          ]
      )

instance Core.ToJSON UpdateLFTag where
  toJSON :: UpdateLFTag -> Value
toJSON UpdateLFTag' {Maybe (NonEmpty Text)
Maybe Text
Text
tagKey :: Text
tagValuesToDelete :: Maybe (NonEmpty Text)
tagValuesToAdd :: Maybe (NonEmpty Text)
catalogId :: Maybe Text
$sel:tagKey:UpdateLFTag' :: UpdateLFTag -> Text
$sel:tagValuesToDelete:UpdateLFTag' :: UpdateLFTag -> Maybe (NonEmpty Text)
$sel:tagValuesToAdd:UpdateLFTag' :: UpdateLFTag -> Maybe (NonEmpty Text)
$sel:catalogId:UpdateLFTag' :: UpdateLFTag -> Maybe Text
..} =
    [Pair] -> Value
Core.object
      ( [Maybe Pair] -> [Pair]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
          [ (Text
"CatalogId" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (Text -> Pair) -> Maybe Text -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Text
catalogId,
            (Text
"TagValuesToAdd" Text -> NonEmpty Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
              (NonEmpty Text -> Pair) -> Maybe (NonEmpty Text) -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (NonEmpty Text)
tagValuesToAdd,
            (Text
"TagValuesToDelete" Text -> NonEmpty Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
              (NonEmpty Text -> Pair) -> Maybe (NonEmpty Text) -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (NonEmpty Text)
tagValuesToDelete,
            Pair -> Maybe Pair
forall a. a -> Maybe a
Prelude.Just (Text
"TagKey" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..= Text
tagKey)
          ]
      )

instance Core.ToPath UpdateLFTag where
  toPath :: UpdateLFTag -> ByteString
toPath = ByteString -> UpdateLFTag -> ByteString
forall a b. a -> b -> a
Prelude.const ByteString
"/"

instance Core.ToQuery UpdateLFTag where
  toQuery :: UpdateLFTag -> QueryString
toQuery = QueryString -> UpdateLFTag -> QueryString
forall a b. a -> b -> a
Prelude.const QueryString
forall a. Monoid a => a
Prelude.mempty

-- | /See:/ 'newUpdateLFTagResponse' smart constructor.
data UpdateLFTagResponse = UpdateLFTagResponse'
  { -- | The response's http status code.
    UpdateLFTagResponse -> Int
httpStatus :: Prelude.Int
  }
  deriving (UpdateLFTagResponse -> UpdateLFTagResponse -> Bool
(UpdateLFTagResponse -> UpdateLFTagResponse -> Bool)
-> (UpdateLFTagResponse -> UpdateLFTagResponse -> Bool)
-> Eq UpdateLFTagResponse
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: UpdateLFTagResponse -> UpdateLFTagResponse -> Bool
$c/= :: UpdateLFTagResponse -> UpdateLFTagResponse -> Bool
== :: UpdateLFTagResponse -> UpdateLFTagResponse -> Bool
$c== :: UpdateLFTagResponse -> UpdateLFTagResponse -> Bool
Prelude.Eq, ReadPrec [UpdateLFTagResponse]
ReadPrec UpdateLFTagResponse
Int -> ReadS UpdateLFTagResponse
ReadS [UpdateLFTagResponse]
(Int -> ReadS UpdateLFTagResponse)
-> ReadS [UpdateLFTagResponse]
-> ReadPrec UpdateLFTagResponse
-> ReadPrec [UpdateLFTagResponse]
-> Read UpdateLFTagResponse
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [UpdateLFTagResponse]
$creadListPrec :: ReadPrec [UpdateLFTagResponse]
readPrec :: ReadPrec UpdateLFTagResponse
$creadPrec :: ReadPrec UpdateLFTagResponse
readList :: ReadS [UpdateLFTagResponse]
$creadList :: ReadS [UpdateLFTagResponse]
readsPrec :: Int -> ReadS UpdateLFTagResponse
$creadsPrec :: Int -> ReadS UpdateLFTagResponse
Prelude.Read, Int -> UpdateLFTagResponse -> ShowS
[UpdateLFTagResponse] -> ShowS
UpdateLFTagResponse -> String
(Int -> UpdateLFTagResponse -> ShowS)
-> (UpdateLFTagResponse -> String)
-> ([UpdateLFTagResponse] -> ShowS)
-> Show UpdateLFTagResponse
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [UpdateLFTagResponse] -> ShowS
$cshowList :: [UpdateLFTagResponse] -> ShowS
show :: UpdateLFTagResponse -> String
$cshow :: UpdateLFTagResponse -> String
showsPrec :: Int -> UpdateLFTagResponse -> ShowS
$cshowsPrec :: Int -> UpdateLFTagResponse -> ShowS
Prelude.Show, (forall x. UpdateLFTagResponse -> Rep UpdateLFTagResponse x)
-> (forall x. Rep UpdateLFTagResponse x -> UpdateLFTagResponse)
-> Generic UpdateLFTagResponse
forall x. Rep UpdateLFTagResponse x -> UpdateLFTagResponse
forall x. UpdateLFTagResponse -> Rep UpdateLFTagResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep UpdateLFTagResponse x -> UpdateLFTagResponse
$cfrom :: forall x. UpdateLFTagResponse -> Rep UpdateLFTagResponse x
Prelude.Generic)

-- |
-- Create a value of 'UpdateLFTagResponse' with all optional fields omitted.
--
-- Use <https://hackage.haskell.org/package/generic-lens generic-lens> or <https://hackage.haskell.org/package/optics optics> to modify other optional fields.
--
-- The following record fields are available, with the corresponding lenses provided
-- for backwards compatibility:
--
-- 'httpStatus', 'updateLFTagResponse_httpStatus' - The response's http status code.
newUpdateLFTagResponse ::
  -- | 'httpStatus'
  Prelude.Int ->
  UpdateLFTagResponse
newUpdateLFTagResponse :: Int -> UpdateLFTagResponse
newUpdateLFTagResponse Int
pHttpStatus_ =
  UpdateLFTagResponse' :: Int -> UpdateLFTagResponse
UpdateLFTagResponse' {$sel:httpStatus:UpdateLFTagResponse' :: Int
httpStatus = Int
pHttpStatus_}

-- | The response's http status code.
updateLFTagResponse_httpStatus :: Lens.Lens' UpdateLFTagResponse Prelude.Int
updateLFTagResponse_httpStatus :: (Int -> f Int) -> UpdateLFTagResponse -> f UpdateLFTagResponse
updateLFTagResponse_httpStatus = (UpdateLFTagResponse -> Int)
-> (UpdateLFTagResponse -> Int -> UpdateLFTagResponse)
-> Lens UpdateLFTagResponse UpdateLFTagResponse Int Int
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateLFTagResponse' {Int
httpStatus :: Int
$sel:httpStatus:UpdateLFTagResponse' :: UpdateLFTagResponse -> Int
httpStatus} -> Int
httpStatus) (\s :: UpdateLFTagResponse
s@UpdateLFTagResponse' {} Int
a -> UpdateLFTagResponse
s {$sel:httpStatus:UpdateLFTagResponse' :: Int
httpStatus = Int
a} :: UpdateLFTagResponse)

instance Prelude.NFData UpdateLFTagResponse