{-# 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.Location.UpdateGeofenceCollection
-- Copyright   : (c) 2013-2023 Brendan Hay
-- License     : Mozilla Public License, v. 2.0.
-- Maintainer  : Brendan Hay
-- Stability   : auto-generated
-- Portability : non-portable (GHC extensions)
--
-- Updates the specified properties of a given geofence collection.
module Amazonka.Location.UpdateGeofenceCollection
  ( -- * Creating a Request
    UpdateGeofenceCollection (..),
    newUpdateGeofenceCollection,

    -- * Request Lenses
    updateGeofenceCollection_description,
    updateGeofenceCollection_pricingPlan,
    updateGeofenceCollection_pricingPlanDataSource,
    updateGeofenceCollection_collectionName,

    -- * Destructuring the Response
    UpdateGeofenceCollectionResponse (..),
    newUpdateGeofenceCollectionResponse,

    -- * Response Lenses
    updateGeofenceCollectionResponse_httpStatus,
    updateGeofenceCollectionResponse_collectionArn,
    updateGeofenceCollectionResponse_collectionName,
    updateGeofenceCollectionResponse_updateTime,
  )
where

import qualified Amazonka.Core as Core
import qualified Amazonka.Core.Lens.Internal as Lens
import qualified Amazonka.Data as Data
import Amazonka.Location.Types
import qualified Amazonka.Prelude as Prelude
import qualified Amazonka.Request as Request
import qualified Amazonka.Response as Response

-- | /See:/ 'newUpdateGeofenceCollection' smart constructor.
data UpdateGeofenceCollection = UpdateGeofenceCollection'
  { -- | Updates the description for the geofence collection.
    UpdateGeofenceCollection -> Maybe Text
description :: Prelude.Maybe Prelude.Text,
    -- | No longer used. If included, the only allowed value is
    -- @RequestBasedUsage@.
    UpdateGeofenceCollection -> Maybe PricingPlan
pricingPlan :: Prelude.Maybe PricingPlan,
    -- | This parameter is no longer used.
    UpdateGeofenceCollection -> Maybe Text
pricingPlanDataSource :: Prelude.Maybe Prelude.Text,
    -- | The name of the geofence collection to update.
    UpdateGeofenceCollection -> Text
collectionName :: Prelude.Text
  }
  deriving (UpdateGeofenceCollection -> UpdateGeofenceCollection -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: UpdateGeofenceCollection -> UpdateGeofenceCollection -> Bool
$c/= :: UpdateGeofenceCollection -> UpdateGeofenceCollection -> Bool
== :: UpdateGeofenceCollection -> UpdateGeofenceCollection -> Bool
$c== :: UpdateGeofenceCollection -> UpdateGeofenceCollection -> Bool
Prelude.Eq, ReadPrec [UpdateGeofenceCollection]
ReadPrec UpdateGeofenceCollection
Int -> ReadS UpdateGeofenceCollection
ReadS [UpdateGeofenceCollection]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [UpdateGeofenceCollection]
$creadListPrec :: ReadPrec [UpdateGeofenceCollection]
readPrec :: ReadPrec UpdateGeofenceCollection
$creadPrec :: ReadPrec UpdateGeofenceCollection
readList :: ReadS [UpdateGeofenceCollection]
$creadList :: ReadS [UpdateGeofenceCollection]
readsPrec :: Int -> ReadS UpdateGeofenceCollection
$creadsPrec :: Int -> ReadS UpdateGeofenceCollection
Prelude.Read, Int -> UpdateGeofenceCollection -> ShowS
[UpdateGeofenceCollection] -> ShowS
UpdateGeofenceCollection -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [UpdateGeofenceCollection] -> ShowS
$cshowList :: [UpdateGeofenceCollection] -> ShowS
show :: UpdateGeofenceCollection -> String
$cshow :: UpdateGeofenceCollection -> String
showsPrec :: Int -> UpdateGeofenceCollection -> ShowS
$cshowsPrec :: Int -> UpdateGeofenceCollection -> ShowS
Prelude.Show, forall x.
Rep UpdateGeofenceCollection x -> UpdateGeofenceCollection
forall x.
UpdateGeofenceCollection -> Rep UpdateGeofenceCollection x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep UpdateGeofenceCollection x -> UpdateGeofenceCollection
$cfrom :: forall x.
UpdateGeofenceCollection -> Rep UpdateGeofenceCollection x
Prelude.Generic)

-- |
-- Create a value of 'UpdateGeofenceCollection' 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:
--
-- 'description', 'updateGeofenceCollection_description' - Updates the description for the geofence collection.
--
-- 'pricingPlan', 'updateGeofenceCollection_pricingPlan' - No longer used. If included, the only allowed value is
-- @RequestBasedUsage@.
--
-- 'pricingPlanDataSource', 'updateGeofenceCollection_pricingPlanDataSource' - This parameter is no longer used.
--
-- 'collectionName', 'updateGeofenceCollection_collectionName' - The name of the geofence collection to update.
newUpdateGeofenceCollection ::
  -- | 'collectionName'
  Prelude.Text ->
  UpdateGeofenceCollection
newUpdateGeofenceCollection :: Text -> UpdateGeofenceCollection
newUpdateGeofenceCollection Text
pCollectionName_ =
  UpdateGeofenceCollection'
    { $sel:description:UpdateGeofenceCollection' :: Maybe Text
description =
        forall a. Maybe a
Prelude.Nothing,
      $sel:pricingPlan:UpdateGeofenceCollection' :: Maybe PricingPlan
pricingPlan = forall a. Maybe a
Prelude.Nothing,
      $sel:pricingPlanDataSource:UpdateGeofenceCollection' :: Maybe Text
pricingPlanDataSource = forall a. Maybe a
Prelude.Nothing,
      $sel:collectionName:UpdateGeofenceCollection' :: Text
collectionName = Text
pCollectionName_
    }

-- | Updates the description for the geofence collection.
updateGeofenceCollection_description :: Lens.Lens' UpdateGeofenceCollection (Prelude.Maybe Prelude.Text)
updateGeofenceCollection_description :: Lens' UpdateGeofenceCollection (Maybe Text)
updateGeofenceCollection_description = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateGeofenceCollection' {Maybe Text
description :: Maybe Text
$sel:description:UpdateGeofenceCollection' :: UpdateGeofenceCollection -> Maybe Text
description} -> Maybe Text
description) (\s :: UpdateGeofenceCollection
s@UpdateGeofenceCollection' {} Maybe Text
a -> UpdateGeofenceCollection
s {$sel:description:UpdateGeofenceCollection' :: Maybe Text
description = Maybe Text
a} :: UpdateGeofenceCollection)

-- | No longer used. If included, the only allowed value is
-- @RequestBasedUsage@.
updateGeofenceCollection_pricingPlan :: Lens.Lens' UpdateGeofenceCollection (Prelude.Maybe PricingPlan)
updateGeofenceCollection_pricingPlan :: Lens' UpdateGeofenceCollection (Maybe PricingPlan)
updateGeofenceCollection_pricingPlan = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateGeofenceCollection' {Maybe PricingPlan
pricingPlan :: Maybe PricingPlan
$sel:pricingPlan:UpdateGeofenceCollection' :: UpdateGeofenceCollection -> Maybe PricingPlan
pricingPlan} -> Maybe PricingPlan
pricingPlan) (\s :: UpdateGeofenceCollection
s@UpdateGeofenceCollection' {} Maybe PricingPlan
a -> UpdateGeofenceCollection
s {$sel:pricingPlan:UpdateGeofenceCollection' :: Maybe PricingPlan
pricingPlan = Maybe PricingPlan
a} :: UpdateGeofenceCollection)

-- | This parameter is no longer used.
updateGeofenceCollection_pricingPlanDataSource :: Lens.Lens' UpdateGeofenceCollection (Prelude.Maybe Prelude.Text)
updateGeofenceCollection_pricingPlanDataSource :: Lens' UpdateGeofenceCollection (Maybe Text)
updateGeofenceCollection_pricingPlanDataSource = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateGeofenceCollection' {Maybe Text
pricingPlanDataSource :: Maybe Text
$sel:pricingPlanDataSource:UpdateGeofenceCollection' :: UpdateGeofenceCollection -> Maybe Text
pricingPlanDataSource} -> Maybe Text
pricingPlanDataSource) (\s :: UpdateGeofenceCollection
s@UpdateGeofenceCollection' {} Maybe Text
a -> UpdateGeofenceCollection
s {$sel:pricingPlanDataSource:UpdateGeofenceCollection' :: Maybe Text
pricingPlanDataSource = Maybe Text
a} :: UpdateGeofenceCollection)

-- | The name of the geofence collection to update.
updateGeofenceCollection_collectionName :: Lens.Lens' UpdateGeofenceCollection Prelude.Text
updateGeofenceCollection_collectionName :: Lens' UpdateGeofenceCollection Text
updateGeofenceCollection_collectionName = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateGeofenceCollection' {Text
collectionName :: Text
$sel:collectionName:UpdateGeofenceCollection' :: UpdateGeofenceCollection -> Text
collectionName} -> Text
collectionName) (\s :: UpdateGeofenceCollection
s@UpdateGeofenceCollection' {} Text
a -> UpdateGeofenceCollection
s {$sel:collectionName:UpdateGeofenceCollection' :: Text
collectionName = Text
a} :: UpdateGeofenceCollection)

instance Core.AWSRequest UpdateGeofenceCollection where
  type
    AWSResponse UpdateGeofenceCollection =
      UpdateGeofenceCollectionResponse
  request :: (Service -> Service)
-> UpdateGeofenceCollection -> Request UpdateGeofenceCollection
request Service -> Service
overrides =
    forall a. (ToRequest a, ToJSON a) => Service -> a -> Request a
Request.patchJSON (Service -> Service
overrides Service
defaultService)
  response :: forall (m :: * -> *).
MonadResource m =>
(ByteStringLazy -> IO ByteStringLazy)
-> Service
-> Proxy UpdateGeofenceCollection
-> ClientResponse ClientBody
-> m (Either
        Error (ClientResponse (AWSResponse UpdateGeofenceCollection)))
response =
    forall (m :: * -> *) a.
MonadResource m =>
(Int -> ResponseHeaders -> Object -> Either String (AWSResponse a))
-> (ByteStringLazy -> IO ByteStringLazy)
-> Service
-> Proxy a
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse a)))
Response.receiveJSON
      ( \Int
s ResponseHeaders
h Object
x ->
          Int -> Text -> Text -> ISO8601 -> UpdateGeofenceCollectionResponse
UpdateGeofenceCollectionResponse'
            forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure (forall a. Enum a => a -> Int
Prelude.fromEnum Int
s))
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Either String a
Data..:> Key
"CollectionArn")
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Either String a
Data..:> Key
"CollectionName")
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Either String a
Data..:> Key
"UpdateTime")
      )

instance Prelude.Hashable UpdateGeofenceCollection where
  hashWithSalt :: Int -> UpdateGeofenceCollection -> Int
hashWithSalt Int
_salt UpdateGeofenceCollection' {Maybe Text
Maybe PricingPlan
Text
collectionName :: Text
pricingPlanDataSource :: Maybe Text
pricingPlan :: Maybe PricingPlan
description :: Maybe Text
$sel:collectionName:UpdateGeofenceCollection' :: UpdateGeofenceCollection -> Text
$sel:pricingPlanDataSource:UpdateGeofenceCollection' :: UpdateGeofenceCollection -> Maybe Text
$sel:pricingPlan:UpdateGeofenceCollection' :: UpdateGeofenceCollection -> Maybe PricingPlan
$sel:description:UpdateGeofenceCollection' :: UpdateGeofenceCollection -> Maybe Text
..} =
    Int
_salt
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
description
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe PricingPlan
pricingPlan
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
pricingPlanDataSource
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Text
collectionName

instance Prelude.NFData UpdateGeofenceCollection where
  rnf :: UpdateGeofenceCollection -> ()
rnf UpdateGeofenceCollection' {Maybe Text
Maybe PricingPlan
Text
collectionName :: Text
pricingPlanDataSource :: Maybe Text
pricingPlan :: Maybe PricingPlan
description :: Maybe Text
$sel:collectionName:UpdateGeofenceCollection' :: UpdateGeofenceCollection -> Text
$sel:pricingPlanDataSource:UpdateGeofenceCollection' :: UpdateGeofenceCollection -> Maybe Text
$sel:pricingPlan:UpdateGeofenceCollection' :: UpdateGeofenceCollection -> Maybe PricingPlan
$sel:description:UpdateGeofenceCollection' :: UpdateGeofenceCollection -> Maybe Text
..} =
    forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
description
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe PricingPlan
pricingPlan
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
pricingPlanDataSource
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Text
collectionName

instance Data.ToHeaders UpdateGeofenceCollection where
  toHeaders :: UpdateGeofenceCollection -> ResponseHeaders
toHeaders =
    forall a b. a -> b -> a
Prelude.const
      ( forall a. Monoid a => [a] -> a
Prelude.mconcat
          [ HeaderName
"Content-Type"
              forall a. ToHeader a => HeaderName -> a -> ResponseHeaders
Data.=# ( ByteString
"application/x-amz-json-1.1" ::
                          Prelude.ByteString
                      )
          ]
      )

instance Data.ToJSON UpdateGeofenceCollection where
  toJSON :: UpdateGeofenceCollection -> Value
toJSON UpdateGeofenceCollection' {Maybe Text
Maybe PricingPlan
Text
collectionName :: Text
pricingPlanDataSource :: Maybe Text
pricingPlan :: Maybe PricingPlan
description :: Maybe Text
$sel:collectionName:UpdateGeofenceCollection' :: UpdateGeofenceCollection -> Text
$sel:pricingPlanDataSource:UpdateGeofenceCollection' :: UpdateGeofenceCollection -> Maybe Text
$sel:pricingPlan:UpdateGeofenceCollection' :: UpdateGeofenceCollection -> Maybe PricingPlan
$sel:description:UpdateGeofenceCollection' :: UpdateGeofenceCollection -> Maybe Text
..} =
    [Pair] -> Value
Data.object
      ( forall a. [Maybe a] -> [a]
Prelude.catMaybes
          [ (Key
"Description" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=) forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Text
description,
            (Key
"PricingPlan" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=) forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe PricingPlan
pricingPlan,
            (Key
"PricingPlanDataSource" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=)
              forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Text
pricingPlanDataSource
          ]
      )

instance Data.ToPath UpdateGeofenceCollection where
  toPath :: UpdateGeofenceCollection -> ByteString
toPath UpdateGeofenceCollection' {Maybe Text
Maybe PricingPlan
Text
collectionName :: Text
pricingPlanDataSource :: Maybe Text
pricingPlan :: Maybe PricingPlan
description :: Maybe Text
$sel:collectionName:UpdateGeofenceCollection' :: UpdateGeofenceCollection -> Text
$sel:pricingPlanDataSource:UpdateGeofenceCollection' :: UpdateGeofenceCollection -> Maybe Text
$sel:pricingPlan:UpdateGeofenceCollection' :: UpdateGeofenceCollection -> Maybe PricingPlan
$sel:description:UpdateGeofenceCollection' :: UpdateGeofenceCollection -> Maybe Text
..} =
    forall a. Monoid a => [a] -> a
Prelude.mconcat
      [ ByteString
"/geofencing/v0/collections/",
        forall a. ToByteString a => a -> ByteString
Data.toBS Text
collectionName
      ]

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

-- | /See:/ 'newUpdateGeofenceCollectionResponse' smart constructor.
data UpdateGeofenceCollectionResponse = UpdateGeofenceCollectionResponse'
  { -- | The response's http status code.
    UpdateGeofenceCollectionResponse -> Int
httpStatus :: Prelude.Int,
    -- | The Amazon Resource Name (ARN) of the updated geofence collection. Used
    -- to specify a resource across AWS.
    --
    -- -   Format example:
    --     @arn:aws:geo:region:account-id:geofence-collection\/ExampleGeofenceCollection@
    UpdateGeofenceCollectionResponse -> Text
collectionArn :: Prelude.Text,
    -- | The name of the updated geofence collection.
    UpdateGeofenceCollectionResponse -> Text
collectionName :: Prelude.Text,
    -- | The time when the geofence collection was last updated in
    -- <https://www.iso.org/iso-8601-date-and-time-format.html ISO 8601>
    -- format: @YYYY-MM-DDThh:mm:ss.sssZ@
    UpdateGeofenceCollectionResponse -> ISO8601
updateTime :: Data.ISO8601
  }
  deriving (UpdateGeofenceCollectionResponse
-> UpdateGeofenceCollectionResponse -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: UpdateGeofenceCollectionResponse
-> UpdateGeofenceCollectionResponse -> Bool
$c/= :: UpdateGeofenceCollectionResponse
-> UpdateGeofenceCollectionResponse -> Bool
== :: UpdateGeofenceCollectionResponse
-> UpdateGeofenceCollectionResponse -> Bool
$c== :: UpdateGeofenceCollectionResponse
-> UpdateGeofenceCollectionResponse -> Bool
Prelude.Eq, ReadPrec [UpdateGeofenceCollectionResponse]
ReadPrec UpdateGeofenceCollectionResponse
Int -> ReadS UpdateGeofenceCollectionResponse
ReadS [UpdateGeofenceCollectionResponse]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [UpdateGeofenceCollectionResponse]
$creadListPrec :: ReadPrec [UpdateGeofenceCollectionResponse]
readPrec :: ReadPrec UpdateGeofenceCollectionResponse
$creadPrec :: ReadPrec UpdateGeofenceCollectionResponse
readList :: ReadS [UpdateGeofenceCollectionResponse]
$creadList :: ReadS [UpdateGeofenceCollectionResponse]
readsPrec :: Int -> ReadS UpdateGeofenceCollectionResponse
$creadsPrec :: Int -> ReadS UpdateGeofenceCollectionResponse
Prelude.Read, Int -> UpdateGeofenceCollectionResponse -> ShowS
[UpdateGeofenceCollectionResponse] -> ShowS
UpdateGeofenceCollectionResponse -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [UpdateGeofenceCollectionResponse] -> ShowS
$cshowList :: [UpdateGeofenceCollectionResponse] -> ShowS
show :: UpdateGeofenceCollectionResponse -> String
$cshow :: UpdateGeofenceCollectionResponse -> String
showsPrec :: Int -> UpdateGeofenceCollectionResponse -> ShowS
$cshowsPrec :: Int -> UpdateGeofenceCollectionResponse -> ShowS
Prelude.Show, forall x.
Rep UpdateGeofenceCollectionResponse x
-> UpdateGeofenceCollectionResponse
forall x.
UpdateGeofenceCollectionResponse
-> Rep UpdateGeofenceCollectionResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep UpdateGeofenceCollectionResponse x
-> UpdateGeofenceCollectionResponse
$cfrom :: forall x.
UpdateGeofenceCollectionResponse
-> Rep UpdateGeofenceCollectionResponse x
Prelude.Generic)

-- |
-- Create a value of 'UpdateGeofenceCollectionResponse' 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', 'updateGeofenceCollectionResponse_httpStatus' - The response's http status code.
--
-- 'collectionArn', 'updateGeofenceCollectionResponse_collectionArn' - The Amazon Resource Name (ARN) of the updated geofence collection. Used
-- to specify a resource across AWS.
--
-- -   Format example:
--     @arn:aws:geo:region:account-id:geofence-collection\/ExampleGeofenceCollection@
--
-- 'collectionName', 'updateGeofenceCollectionResponse_collectionName' - The name of the updated geofence collection.
--
-- 'updateTime', 'updateGeofenceCollectionResponse_updateTime' - The time when the geofence collection was last updated in
-- <https://www.iso.org/iso-8601-date-and-time-format.html ISO 8601>
-- format: @YYYY-MM-DDThh:mm:ss.sssZ@
newUpdateGeofenceCollectionResponse ::
  -- | 'httpStatus'
  Prelude.Int ->
  -- | 'collectionArn'
  Prelude.Text ->
  -- | 'collectionName'
  Prelude.Text ->
  -- | 'updateTime'
  Prelude.UTCTime ->
  UpdateGeofenceCollectionResponse
newUpdateGeofenceCollectionResponse :: Int -> Text -> Text -> UTCTime -> UpdateGeofenceCollectionResponse
newUpdateGeofenceCollectionResponse
  Int
pHttpStatus_
  Text
pCollectionArn_
  Text
pCollectionName_
  UTCTime
pUpdateTime_ =
    UpdateGeofenceCollectionResponse'
      { $sel:httpStatus:UpdateGeofenceCollectionResponse' :: Int
httpStatus =
          Int
pHttpStatus_,
        $sel:collectionArn:UpdateGeofenceCollectionResponse' :: Text
collectionArn = Text
pCollectionArn_,
        $sel:collectionName:UpdateGeofenceCollectionResponse' :: Text
collectionName = Text
pCollectionName_,
        $sel:updateTime:UpdateGeofenceCollectionResponse' :: ISO8601
updateTime =
          forall (a :: Format). Iso' (Time a) UTCTime
Data._Time forall t b. AReview t b -> b -> t
Lens.# UTCTime
pUpdateTime_
      }

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

-- | The Amazon Resource Name (ARN) of the updated geofence collection. Used
-- to specify a resource across AWS.
--
-- -   Format example:
--     @arn:aws:geo:region:account-id:geofence-collection\/ExampleGeofenceCollection@
updateGeofenceCollectionResponse_collectionArn :: Lens.Lens' UpdateGeofenceCollectionResponse Prelude.Text
updateGeofenceCollectionResponse_collectionArn :: Lens' UpdateGeofenceCollectionResponse Text
updateGeofenceCollectionResponse_collectionArn = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateGeofenceCollectionResponse' {Text
collectionArn :: Text
$sel:collectionArn:UpdateGeofenceCollectionResponse' :: UpdateGeofenceCollectionResponse -> Text
collectionArn} -> Text
collectionArn) (\s :: UpdateGeofenceCollectionResponse
s@UpdateGeofenceCollectionResponse' {} Text
a -> UpdateGeofenceCollectionResponse
s {$sel:collectionArn:UpdateGeofenceCollectionResponse' :: Text
collectionArn = Text
a} :: UpdateGeofenceCollectionResponse)

-- | The name of the updated geofence collection.
updateGeofenceCollectionResponse_collectionName :: Lens.Lens' UpdateGeofenceCollectionResponse Prelude.Text
updateGeofenceCollectionResponse_collectionName :: Lens' UpdateGeofenceCollectionResponse Text
updateGeofenceCollectionResponse_collectionName = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateGeofenceCollectionResponse' {Text
collectionName :: Text
$sel:collectionName:UpdateGeofenceCollectionResponse' :: UpdateGeofenceCollectionResponse -> Text
collectionName} -> Text
collectionName) (\s :: UpdateGeofenceCollectionResponse
s@UpdateGeofenceCollectionResponse' {} Text
a -> UpdateGeofenceCollectionResponse
s {$sel:collectionName:UpdateGeofenceCollectionResponse' :: Text
collectionName = Text
a} :: UpdateGeofenceCollectionResponse)

-- | The time when the geofence collection was last updated in
-- <https://www.iso.org/iso-8601-date-and-time-format.html ISO 8601>
-- format: @YYYY-MM-DDThh:mm:ss.sssZ@
updateGeofenceCollectionResponse_updateTime :: Lens.Lens' UpdateGeofenceCollectionResponse Prelude.UTCTime
updateGeofenceCollectionResponse_updateTime :: Lens' UpdateGeofenceCollectionResponse UTCTime
updateGeofenceCollectionResponse_updateTime = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateGeofenceCollectionResponse' {ISO8601
updateTime :: ISO8601
$sel:updateTime:UpdateGeofenceCollectionResponse' :: UpdateGeofenceCollectionResponse -> ISO8601
updateTime} -> ISO8601
updateTime) (\s :: UpdateGeofenceCollectionResponse
s@UpdateGeofenceCollectionResponse' {} ISO8601
a -> UpdateGeofenceCollectionResponse
s {$sel:updateTime:UpdateGeofenceCollectionResponse' :: ISO8601
updateTime = ISO8601
a} :: UpdateGeofenceCollectionResponse) forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. forall (a :: Format). Iso' (Time a) UTCTime
Data._Time

instance
  Prelude.NFData
    UpdateGeofenceCollectionResponse
  where
  rnf :: UpdateGeofenceCollectionResponse -> ()
rnf UpdateGeofenceCollectionResponse' {Int
Text
ISO8601
updateTime :: ISO8601
collectionName :: Text
collectionArn :: Text
httpStatus :: Int
$sel:updateTime:UpdateGeofenceCollectionResponse' :: UpdateGeofenceCollectionResponse -> ISO8601
$sel:collectionName:UpdateGeofenceCollectionResponse' :: UpdateGeofenceCollectionResponse -> Text
$sel:collectionArn:UpdateGeofenceCollectionResponse' :: UpdateGeofenceCollectionResponse -> Text
$sel:httpStatus:UpdateGeofenceCollectionResponse' :: UpdateGeofenceCollectionResponse -> Int
..} =
    forall a. NFData a => a -> ()
Prelude.rnf Int
httpStatus
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Text
collectionArn
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Text
collectionName
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf ISO8601
updateTime