{-# 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.ListTrackersResponseEntry where
import qualified Amazonka.Core as Core
import qualified Amazonka.Lens as Lens
import Amazonka.Location.Types.PricingPlan
import qualified Amazonka.Prelude as Prelude
data ListTrackersResponseEntry = ListTrackersResponseEntry'
{
ListTrackersResponseEntry -> Maybe Text
pricingPlanDataSource :: Prelude.Maybe Prelude.Text,
ListTrackersResponseEntry -> POSIX
createTime :: Core.POSIX,
ListTrackersResponseEntry -> Text
description :: Prelude.Text,
ListTrackersResponseEntry -> PricingPlan
pricingPlan :: PricingPlan,
ListTrackersResponseEntry -> Text
trackerName :: Prelude.Text,
ListTrackersResponseEntry -> POSIX
updateTime :: Core.POSIX
}
deriving (ListTrackersResponseEntry -> ListTrackersResponseEntry -> Bool
(ListTrackersResponseEntry -> ListTrackersResponseEntry -> Bool)
-> (ListTrackersResponseEntry -> ListTrackersResponseEntry -> Bool)
-> Eq ListTrackersResponseEntry
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: ListTrackersResponseEntry -> ListTrackersResponseEntry -> Bool
$c/= :: ListTrackersResponseEntry -> ListTrackersResponseEntry -> Bool
== :: ListTrackersResponseEntry -> ListTrackersResponseEntry -> Bool
$c== :: ListTrackersResponseEntry -> ListTrackersResponseEntry -> Bool
Prelude.Eq, ReadPrec [ListTrackersResponseEntry]
ReadPrec ListTrackersResponseEntry
Int -> ReadS ListTrackersResponseEntry
ReadS [ListTrackersResponseEntry]
(Int -> ReadS ListTrackersResponseEntry)
-> ReadS [ListTrackersResponseEntry]
-> ReadPrec ListTrackersResponseEntry
-> ReadPrec [ListTrackersResponseEntry]
-> Read ListTrackersResponseEntry
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [ListTrackersResponseEntry]
$creadListPrec :: ReadPrec [ListTrackersResponseEntry]
readPrec :: ReadPrec ListTrackersResponseEntry
$creadPrec :: ReadPrec ListTrackersResponseEntry
readList :: ReadS [ListTrackersResponseEntry]
$creadList :: ReadS [ListTrackersResponseEntry]
readsPrec :: Int -> ReadS ListTrackersResponseEntry
$creadsPrec :: Int -> ReadS ListTrackersResponseEntry
Prelude.Read, Int -> ListTrackersResponseEntry -> ShowS
[ListTrackersResponseEntry] -> ShowS
ListTrackersResponseEntry -> String
(Int -> ListTrackersResponseEntry -> ShowS)
-> (ListTrackersResponseEntry -> String)
-> ([ListTrackersResponseEntry] -> ShowS)
-> Show ListTrackersResponseEntry
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [ListTrackersResponseEntry] -> ShowS
$cshowList :: [ListTrackersResponseEntry] -> ShowS
show :: ListTrackersResponseEntry -> String
$cshow :: ListTrackersResponseEntry -> String
showsPrec :: Int -> ListTrackersResponseEntry -> ShowS
$cshowsPrec :: Int -> ListTrackersResponseEntry -> ShowS
Prelude.Show, (forall x.
ListTrackersResponseEntry -> Rep ListTrackersResponseEntry x)
-> (forall x.
Rep ListTrackersResponseEntry x -> ListTrackersResponseEntry)
-> Generic ListTrackersResponseEntry
forall x.
Rep ListTrackersResponseEntry x -> ListTrackersResponseEntry
forall x.
ListTrackersResponseEntry -> Rep ListTrackersResponseEntry x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep ListTrackersResponseEntry x -> ListTrackersResponseEntry
$cfrom :: forall x.
ListTrackersResponseEntry -> Rep ListTrackersResponseEntry x
Prelude.Generic)
newListTrackersResponseEntry ::
Prelude.UTCTime ->
Prelude.Text ->
PricingPlan ->
Prelude.Text ->
Prelude.UTCTime ->
ListTrackersResponseEntry
newListTrackersResponseEntry :: UTCTime
-> Text
-> PricingPlan
-> Text
-> UTCTime
-> ListTrackersResponseEntry
newListTrackersResponseEntry
UTCTime
pCreateTime_
Text
pDescription_
PricingPlan
pPricingPlan_
Text
pTrackerName_
UTCTime
pUpdateTime_ =
ListTrackersResponseEntry' :: Maybe Text
-> POSIX
-> Text
-> PricingPlan
-> Text
-> POSIX
-> ListTrackersResponseEntry
ListTrackersResponseEntry'
{ $sel:pricingPlanDataSource:ListTrackersResponseEntry' :: Maybe Text
pricingPlanDataSource =
Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:createTime:ListTrackersResponseEntry' :: POSIX
createTime = Tagged UTCTime (Identity UTCTime) -> Tagged POSIX (Identity POSIX)
forall (a :: Format). Iso' (Time a) UTCTime
Core._Time (Tagged UTCTime (Identity UTCTime)
-> Tagged POSIX (Identity POSIX))
-> UTCTime -> POSIX
forall t b. AReview t b -> b -> t
Lens.# UTCTime
pCreateTime_,
$sel:description:ListTrackersResponseEntry' :: Text
description = Text
pDescription_,
$sel:pricingPlan:ListTrackersResponseEntry' :: PricingPlan
pricingPlan = PricingPlan
pPricingPlan_,
$sel:trackerName:ListTrackersResponseEntry' :: Text
trackerName = Text
pTrackerName_,
$sel:updateTime:ListTrackersResponseEntry' :: POSIX
updateTime = Tagged UTCTime (Identity UTCTime) -> Tagged POSIX (Identity POSIX)
forall (a :: Format). Iso' (Time a) UTCTime
Core._Time (Tagged UTCTime (Identity UTCTime)
-> Tagged POSIX (Identity POSIX))
-> UTCTime -> POSIX
forall t b. AReview t b -> b -> t
Lens.# UTCTime
pUpdateTime_
}
listTrackersResponseEntry_pricingPlanDataSource :: Lens.Lens' ListTrackersResponseEntry (Prelude.Maybe Prelude.Text)
listTrackersResponseEntry_pricingPlanDataSource :: (Maybe Text -> f (Maybe Text))
-> ListTrackersResponseEntry -> f ListTrackersResponseEntry
listTrackersResponseEntry_pricingPlanDataSource = (ListTrackersResponseEntry -> Maybe Text)
-> (ListTrackersResponseEntry
-> Maybe Text -> ListTrackersResponseEntry)
-> Lens
ListTrackersResponseEntry
ListTrackersResponseEntry
(Maybe Text)
(Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListTrackersResponseEntry' {Maybe Text
pricingPlanDataSource :: Maybe Text
$sel:pricingPlanDataSource:ListTrackersResponseEntry' :: ListTrackersResponseEntry -> Maybe Text
pricingPlanDataSource} -> Maybe Text
pricingPlanDataSource) (\s :: ListTrackersResponseEntry
s@ListTrackersResponseEntry' {} Maybe Text
a -> ListTrackersResponseEntry
s {$sel:pricingPlanDataSource:ListTrackersResponseEntry' :: Maybe Text
pricingPlanDataSource = Maybe Text
a} :: ListTrackersResponseEntry)
listTrackersResponseEntry_createTime :: Lens.Lens' ListTrackersResponseEntry Prelude.UTCTime
listTrackersResponseEntry_createTime :: (UTCTime -> f UTCTime)
-> ListTrackersResponseEntry -> f ListTrackersResponseEntry
listTrackersResponseEntry_createTime = (ListTrackersResponseEntry -> POSIX)
-> (ListTrackersResponseEntry
-> POSIX -> ListTrackersResponseEntry)
-> Lens
ListTrackersResponseEntry ListTrackersResponseEntry POSIX POSIX
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListTrackersResponseEntry' {POSIX
createTime :: POSIX
$sel:createTime:ListTrackersResponseEntry' :: ListTrackersResponseEntry -> POSIX
createTime} -> POSIX
createTime) (\s :: ListTrackersResponseEntry
s@ListTrackersResponseEntry' {} POSIX
a -> ListTrackersResponseEntry
s {$sel:createTime:ListTrackersResponseEntry' :: POSIX
createTime = POSIX
a} :: ListTrackersResponseEntry) ((POSIX -> f POSIX)
-> ListTrackersResponseEntry -> f ListTrackersResponseEntry)
-> ((UTCTime -> f UTCTime) -> POSIX -> f POSIX)
-> (UTCTime -> f UTCTime)
-> ListTrackersResponseEntry
-> f ListTrackersResponseEntry
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. (UTCTime -> f UTCTime) -> POSIX -> f POSIX
forall (a :: Format). Iso' (Time a) UTCTime
Core._Time
listTrackersResponseEntry_description :: Lens.Lens' ListTrackersResponseEntry Prelude.Text
listTrackersResponseEntry_description :: (Text -> f Text)
-> ListTrackersResponseEntry -> f ListTrackersResponseEntry
listTrackersResponseEntry_description = (ListTrackersResponseEntry -> Text)
-> (ListTrackersResponseEntry -> Text -> ListTrackersResponseEntry)
-> Lens
ListTrackersResponseEntry ListTrackersResponseEntry Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListTrackersResponseEntry' {Text
description :: Text
$sel:description:ListTrackersResponseEntry' :: ListTrackersResponseEntry -> Text
description} -> Text
description) (\s :: ListTrackersResponseEntry
s@ListTrackersResponseEntry' {} Text
a -> ListTrackersResponseEntry
s {$sel:description:ListTrackersResponseEntry' :: Text
description = Text
a} :: ListTrackersResponseEntry)
listTrackersResponseEntry_pricingPlan :: Lens.Lens' ListTrackersResponseEntry PricingPlan
listTrackersResponseEntry_pricingPlan :: (PricingPlan -> f PricingPlan)
-> ListTrackersResponseEntry -> f ListTrackersResponseEntry
listTrackersResponseEntry_pricingPlan = (ListTrackersResponseEntry -> PricingPlan)
-> (ListTrackersResponseEntry
-> PricingPlan -> ListTrackersResponseEntry)
-> Lens
ListTrackersResponseEntry
ListTrackersResponseEntry
PricingPlan
PricingPlan
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListTrackersResponseEntry' {PricingPlan
pricingPlan :: PricingPlan
$sel:pricingPlan:ListTrackersResponseEntry' :: ListTrackersResponseEntry -> PricingPlan
pricingPlan} -> PricingPlan
pricingPlan) (\s :: ListTrackersResponseEntry
s@ListTrackersResponseEntry' {} PricingPlan
a -> ListTrackersResponseEntry
s {$sel:pricingPlan:ListTrackersResponseEntry' :: PricingPlan
pricingPlan = PricingPlan
a} :: ListTrackersResponseEntry)
listTrackersResponseEntry_trackerName :: Lens.Lens' ListTrackersResponseEntry Prelude.Text
listTrackersResponseEntry_trackerName :: (Text -> f Text)
-> ListTrackersResponseEntry -> f ListTrackersResponseEntry
listTrackersResponseEntry_trackerName = (ListTrackersResponseEntry -> Text)
-> (ListTrackersResponseEntry -> Text -> ListTrackersResponseEntry)
-> Lens
ListTrackersResponseEntry ListTrackersResponseEntry Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListTrackersResponseEntry' {Text
trackerName :: Text
$sel:trackerName:ListTrackersResponseEntry' :: ListTrackersResponseEntry -> Text
trackerName} -> Text
trackerName) (\s :: ListTrackersResponseEntry
s@ListTrackersResponseEntry' {} Text
a -> ListTrackersResponseEntry
s {$sel:trackerName:ListTrackersResponseEntry' :: Text
trackerName = Text
a} :: ListTrackersResponseEntry)
listTrackersResponseEntry_updateTime :: Lens.Lens' ListTrackersResponseEntry Prelude.UTCTime
listTrackersResponseEntry_updateTime :: (UTCTime -> f UTCTime)
-> ListTrackersResponseEntry -> f ListTrackersResponseEntry
listTrackersResponseEntry_updateTime = (ListTrackersResponseEntry -> POSIX)
-> (ListTrackersResponseEntry
-> POSIX -> ListTrackersResponseEntry)
-> Lens
ListTrackersResponseEntry ListTrackersResponseEntry POSIX POSIX
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListTrackersResponseEntry' {POSIX
updateTime :: POSIX
$sel:updateTime:ListTrackersResponseEntry' :: ListTrackersResponseEntry -> POSIX
updateTime} -> POSIX
updateTime) (\s :: ListTrackersResponseEntry
s@ListTrackersResponseEntry' {} POSIX
a -> ListTrackersResponseEntry
s {$sel:updateTime:ListTrackersResponseEntry' :: POSIX
updateTime = POSIX
a} :: ListTrackersResponseEntry) ((POSIX -> f POSIX)
-> ListTrackersResponseEntry -> f ListTrackersResponseEntry)
-> ((UTCTime -> f UTCTime) -> POSIX -> f POSIX)
-> (UTCTime -> f UTCTime)
-> ListTrackersResponseEntry
-> f ListTrackersResponseEntry
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. (UTCTime -> f UTCTime) -> POSIX -> f POSIX
forall (a :: Format). Iso' (Time a) UTCTime
Core._Time
instance Core.FromJSON ListTrackersResponseEntry where
parseJSON :: Value -> Parser ListTrackersResponseEntry
parseJSON =
String
-> (Object -> Parser ListTrackersResponseEntry)
-> Value
-> Parser ListTrackersResponseEntry
forall a. String -> (Object -> Parser a) -> Value -> Parser a
Core.withObject
String
"ListTrackersResponseEntry"
( \Object
x ->
Maybe Text
-> POSIX
-> Text
-> PricingPlan
-> Text
-> POSIX
-> ListTrackersResponseEntry
ListTrackersResponseEntry'
(Maybe Text
-> POSIX
-> Text
-> PricingPlan
-> Text
-> POSIX
-> ListTrackersResponseEntry)
-> Parser (Maybe Text)
-> Parser
(POSIX
-> Text
-> PricingPlan
-> Text
-> POSIX
-> ListTrackersResponseEntry)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Object
x Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"PricingPlanDataSource")
Parser
(POSIX
-> Text
-> PricingPlan
-> Text
-> POSIX
-> ListTrackersResponseEntry)
-> Parser POSIX
-> Parser
(Text -> PricingPlan -> Text -> POSIX -> ListTrackersResponseEntry)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser POSIX
forall a. FromJSON a => Object -> Text -> Parser a
Core..: Text
"CreateTime")
Parser
(Text -> PricingPlan -> Text -> POSIX -> ListTrackersResponseEntry)
-> Parser Text
-> Parser
(PricingPlan -> Text -> POSIX -> ListTrackersResponseEntry)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser Text
forall a. FromJSON a => Object -> Text -> Parser a
Core..: Text
"Description")
Parser (PricingPlan -> Text -> POSIX -> ListTrackersResponseEntry)
-> Parser PricingPlan
-> Parser (Text -> POSIX -> ListTrackersResponseEntry)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser PricingPlan
forall a. FromJSON a => Object -> Text -> Parser a
Core..: Text
"PricingPlan")
Parser (Text -> POSIX -> ListTrackersResponseEntry)
-> Parser Text -> Parser (POSIX -> ListTrackersResponseEntry)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser Text
forall a. FromJSON a => Object -> Text -> Parser a
Core..: Text
"TrackerName")
Parser (POSIX -> ListTrackersResponseEntry)
-> Parser POSIX -> Parser ListTrackersResponseEntry
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser POSIX
forall a. FromJSON a => Object -> Text -> Parser a
Core..: Text
"UpdateTime")
)
instance Prelude.Hashable ListTrackersResponseEntry
instance Prelude.NFData ListTrackersResponseEntry