{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE DuplicateRecordFields #-}
{-# LANGUAGE NamedFieldPuns #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE StrictData #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-unused-matches #-}
module Amazonka.Location.Types.ListMapsResponseEntry 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.PricingPlan
import qualified Amazonka.Prelude as Prelude
data ListMapsResponseEntry = ListMapsResponseEntry'
{
ListMapsResponseEntry -> Maybe PricingPlan
pricingPlan :: Prelude.Maybe PricingPlan,
ListMapsResponseEntry -> ISO8601
createTime :: Data.ISO8601,
ListMapsResponseEntry -> Text
dataSource :: Prelude.Text,
ListMapsResponseEntry -> Text
description :: Prelude.Text,
ListMapsResponseEntry -> Text
mapName :: Prelude.Text,
ListMapsResponseEntry -> ISO8601
updateTime :: Data.ISO8601
}
deriving (ListMapsResponseEntry -> ListMapsResponseEntry -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: ListMapsResponseEntry -> ListMapsResponseEntry -> Bool
$c/= :: ListMapsResponseEntry -> ListMapsResponseEntry -> Bool
== :: ListMapsResponseEntry -> ListMapsResponseEntry -> Bool
$c== :: ListMapsResponseEntry -> ListMapsResponseEntry -> Bool
Prelude.Eq, ReadPrec [ListMapsResponseEntry]
ReadPrec ListMapsResponseEntry
Int -> ReadS ListMapsResponseEntry
ReadS [ListMapsResponseEntry]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [ListMapsResponseEntry]
$creadListPrec :: ReadPrec [ListMapsResponseEntry]
readPrec :: ReadPrec ListMapsResponseEntry
$creadPrec :: ReadPrec ListMapsResponseEntry
readList :: ReadS [ListMapsResponseEntry]
$creadList :: ReadS [ListMapsResponseEntry]
readsPrec :: Int -> ReadS ListMapsResponseEntry
$creadsPrec :: Int -> ReadS ListMapsResponseEntry
Prelude.Read, Int -> ListMapsResponseEntry -> ShowS
[ListMapsResponseEntry] -> ShowS
ListMapsResponseEntry -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [ListMapsResponseEntry] -> ShowS
$cshowList :: [ListMapsResponseEntry] -> ShowS
show :: ListMapsResponseEntry -> String
$cshow :: ListMapsResponseEntry -> String
showsPrec :: Int -> ListMapsResponseEntry -> ShowS
$cshowsPrec :: Int -> ListMapsResponseEntry -> ShowS
Prelude.Show, forall x. Rep ListMapsResponseEntry x -> ListMapsResponseEntry
forall x. ListMapsResponseEntry -> Rep ListMapsResponseEntry x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep ListMapsResponseEntry x -> ListMapsResponseEntry
$cfrom :: forall x. ListMapsResponseEntry -> Rep ListMapsResponseEntry x
Prelude.Generic)
newListMapsResponseEntry ::
Prelude.UTCTime ->
Prelude.Text ->
Prelude.Text ->
Prelude.Text ->
Prelude.UTCTime ->
ListMapsResponseEntry
newListMapsResponseEntry :: UTCTime -> Text -> Text -> Text -> UTCTime -> ListMapsResponseEntry
newListMapsResponseEntry
UTCTime
pCreateTime_
Text
pDataSource_
Text
pDescription_
Text
pMapName_
UTCTime
pUpdateTime_ =
ListMapsResponseEntry'
{ $sel:pricingPlan:ListMapsResponseEntry' :: Maybe PricingPlan
pricingPlan =
forall a. Maybe a
Prelude.Nothing,
$sel:createTime:ListMapsResponseEntry' :: ISO8601
createTime = forall (a :: Format). Iso' (Time a) UTCTime
Data._Time forall t b. AReview t b -> b -> t
Lens.# UTCTime
pCreateTime_,
$sel:dataSource:ListMapsResponseEntry' :: Text
dataSource = Text
pDataSource_,
$sel:description:ListMapsResponseEntry' :: Text
description = Text
pDescription_,
$sel:mapName:ListMapsResponseEntry' :: Text
mapName = Text
pMapName_,
$sel:updateTime:ListMapsResponseEntry' :: ISO8601
updateTime = forall (a :: Format). Iso' (Time a) UTCTime
Data._Time forall t b. AReview t b -> b -> t
Lens.# UTCTime
pUpdateTime_
}
listMapsResponseEntry_pricingPlan :: Lens.Lens' ListMapsResponseEntry (Prelude.Maybe PricingPlan)
listMapsResponseEntry_pricingPlan :: Lens' ListMapsResponseEntry (Maybe PricingPlan)
listMapsResponseEntry_pricingPlan = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListMapsResponseEntry' {Maybe PricingPlan
pricingPlan :: Maybe PricingPlan
$sel:pricingPlan:ListMapsResponseEntry' :: ListMapsResponseEntry -> Maybe PricingPlan
pricingPlan} -> Maybe PricingPlan
pricingPlan) (\s :: ListMapsResponseEntry
s@ListMapsResponseEntry' {} Maybe PricingPlan
a -> ListMapsResponseEntry
s {$sel:pricingPlan:ListMapsResponseEntry' :: Maybe PricingPlan
pricingPlan = Maybe PricingPlan
a} :: ListMapsResponseEntry)
listMapsResponseEntry_createTime :: Lens.Lens' ListMapsResponseEntry Prelude.UTCTime
listMapsResponseEntry_createTime :: Lens' ListMapsResponseEntry UTCTime
listMapsResponseEntry_createTime = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListMapsResponseEntry' {ISO8601
createTime :: ISO8601
$sel:createTime:ListMapsResponseEntry' :: ListMapsResponseEntry -> ISO8601
createTime} -> ISO8601
createTime) (\s :: ListMapsResponseEntry
s@ListMapsResponseEntry' {} ISO8601
a -> ListMapsResponseEntry
s {$sel:createTime:ListMapsResponseEntry' :: ISO8601
createTime = ISO8601
a} :: ListMapsResponseEntry) forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. forall (a :: Format). Iso' (Time a) UTCTime
Data._Time
listMapsResponseEntry_dataSource :: Lens.Lens' ListMapsResponseEntry Prelude.Text
listMapsResponseEntry_dataSource :: Lens' ListMapsResponseEntry Text
listMapsResponseEntry_dataSource = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListMapsResponseEntry' {Text
dataSource :: Text
$sel:dataSource:ListMapsResponseEntry' :: ListMapsResponseEntry -> Text
dataSource} -> Text
dataSource) (\s :: ListMapsResponseEntry
s@ListMapsResponseEntry' {} Text
a -> ListMapsResponseEntry
s {$sel:dataSource:ListMapsResponseEntry' :: Text
dataSource = Text
a} :: ListMapsResponseEntry)
listMapsResponseEntry_description :: Lens.Lens' ListMapsResponseEntry Prelude.Text
listMapsResponseEntry_description :: Lens' ListMapsResponseEntry Text
listMapsResponseEntry_description = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListMapsResponseEntry' {Text
description :: Text
$sel:description:ListMapsResponseEntry' :: ListMapsResponseEntry -> Text
description} -> Text
description) (\s :: ListMapsResponseEntry
s@ListMapsResponseEntry' {} Text
a -> ListMapsResponseEntry
s {$sel:description:ListMapsResponseEntry' :: Text
description = Text
a} :: ListMapsResponseEntry)
listMapsResponseEntry_mapName :: Lens.Lens' ListMapsResponseEntry Prelude.Text
listMapsResponseEntry_mapName :: Lens' ListMapsResponseEntry Text
listMapsResponseEntry_mapName = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListMapsResponseEntry' {Text
mapName :: Text
$sel:mapName:ListMapsResponseEntry' :: ListMapsResponseEntry -> Text
mapName} -> Text
mapName) (\s :: ListMapsResponseEntry
s@ListMapsResponseEntry' {} Text
a -> ListMapsResponseEntry
s {$sel:mapName:ListMapsResponseEntry' :: Text
mapName = Text
a} :: ListMapsResponseEntry)
listMapsResponseEntry_updateTime :: Lens.Lens' ListMapsResponseEntry Prelude.UTCTime
listMapsResponseEntry_updateTime :: Lens' ListMapsResponseEntry UTCTime
listMapsResponseEntry_updateTime = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListMapsResponseEntry' {ISO8601
updateTime :: ISO8601
$sel:updateTime:ListMapsResponseEntry' :: ListMapsResponseEntry -> ISO8601
updateTime} -> ISO8601
updateTime) (\s :: ListMapsResponseEntry
s@ListMapsResponseEntry' {} ISO8601
a -> ListMapsResponseEntry
s {$sel:updateTime:ListMapsResponseEntry' :: ISO8601
updateTime = ISO8601
a} :: ListMapsResponseEntry) forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. forall (a :: Format). Iso' (Time a) UTCTime
Data._Time
instance Data.FromJSON ListMapsResponseEntry where
parseJSON :: Value -> Parser ListMapsResponseEntry
parseJSON =
forall a. String -> (Object -> Parser a) -> Value -> Parser a
Data.withObject
String
"ListMapsResponseEntry"
( \Object
x ->
Maybe PricingPlan
-> ISO8601
-> Text
-> Text
-> Text
-> ISO8601
-> ListMapsResponseEntry
ListMapsResponseEntry'
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"PricingPlan")
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser a
Data..: Key
"CreateTime")
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser a
Data..: Key
"DataSource")
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser a
Data..: Key
"Description")
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser a
Data..: Key
"MapName")
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser a
Data..: Key
"UpdateTime")
)
instance Prelude.Hashable ListMapsResponseEntry where
hashWithSalt :: Int -> ListMapsResponseEntry -> Int
hashWithSalt Int
_salt ListMapsResponseEntry' {Maybe PricingPlan
Text
ISO8601
updateTime :: ISO8601
mapName :: Text
description :: Text
dataSource :: Text
createTime :: ISO8601
pricingPlan :: Maybe PricingPlan
$sel:updateTime:ListMapsResponseEntry' :: ListMapsResponseEntry -> ISO8601
$sel:mapName:ListMapsResponseEntry' :: ListMapsResponseEntry -> Text
$sel:description:ListMapsResponseEntry' :: ListMapsResponseEntry -> Text
$sel:dataSource:ListMapsResponseEntry' :: ListMapsResponseEntry -> Text
$sel:createTime:ListMapsResponseEntry' :: ListMapsResponseEntry -> ISO8601
$sel:pricingPlan:ListMapsResponseEntry' :: ListMapsResponseEntry -> Maybe PricingPlan
..} =
Int
_salt
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe PricingPlan
pricingPlan
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` ISO8601
createTime
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Text
dataSource
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Text
description
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Text
mapName
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` ISO8601
updateTime
instance Prelude.NFData ListMapsResponseEntry where
rnf :: ListMapsResponseEntry -> ()
rnf ListMapsResponseEntry' {Maybe PricingPlan
Text
ISO8601
updateTime :: ISO8601
mapName :: Text
description :: Text
dataSource :: Text
createTime :: ISO8601
pricingPlan :: Maybe PricingPlan
$sel:updateTime:ListMapsResponseEntry' :: ListMapsResponseEntry -> ISO8601
$sel:mapName:ListMapsResponseEntry' :: ListMapsResponseEntry -> Text
$sel:description:ListMapsResponseEntry' :: ListMapsResponseEntry -> Text
$sel:dataSource:ListMapsResponseEntry' :: ListMapsResponseEntry -> Text
$sel:createTime:ListMapsResponseEntry' :: ListMapsResponseEntry -> ISO8601
$sel:pricingPlan:ListMapsResponseEntry' :: ListMapsResponseEntry -> Maybe PricingPlan
..} =
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 ISO8601
createTime
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Text
dataSource
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Text
description
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Text
mapName
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf ISO8601
updateTime