{-# 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 #-}
module Amazonka.Location.CreateTracker
(
CreateTracker (..),
newCreateTracker,
createTracker_pricingPlanDataSource,
createTracker_kmsKeyId,
createTracker_description,
createTracker_tags,
createTracker_positionFiltering,
createTracker_pricingPlan,
createTracker_trackerName,
CreateTrackerResponse (..),
newCreateTrackerResponse,
createTrackerResponse_httpStatus,
createTrackerResponse_createTime,
createTrackerResponse_trackerArn,
createTrackerResponse_trackerName,
)
where
import qualified Amazonka.Core as Core
import qualified Amazonka.Lens as Lens
import Amazonka.Location.Types
import qualified Amazonka.Prelude as Prelude
import qualified Amazonka.Request as Request
import qualified Amazonka.Response as Response
data CreateTracker = CreateTracker'
{
CreateTracker -> Maybe Text
pricingPlanDataSource :: Prelude.Maybe Prelude.Text,
CreateTracker -> Maybe Text
kmsKeyId :: Prelude.Maybe Prelude.Text,
CreateTracker -> Maybe Text
description :: Prelude.Maybe Prelude.Text,
CreateTracker -> Maybe (HashMap Text Text)
tags :: Prelude.Maybe (Prelude.HashMap Prelude.Text Prelude.Text),
CreateTracker -> Maybe PositionFiltering
positionFiltering :: Prelude.Maybe PositionFiltering,
CreateTracker -> PricingPlan
pricingPlan :: PricingPlan,
CreateTracker -> Text
trackerName :: Prelude.Text
}
deriving (CreateTracker -> CreateTracker -> Bool
(CreateTracker -> CreateTracker -> Bool)
-> (CreateTracker -> CreateTracker -> Bool) -> Eq CreateTracker
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: CreateTracker -> CreateTracker -> Bool
$c/= :: CreateTracker -> CreateTracker -> Bool
== :: CreateTracker -> CreateTracker -> Bool
$c== :: CreateTracker -> CreateTracker -> Bool
Prelude.Eq, ReadPrec [CreateTracker]
ReadPrec CreateTracker
Int -> ReadS CreateTracker
ReadS [CreateTracker]
(Int -> ReadS CreateTracker)
-> ReadS [CreateTracker]
-> ReadPrec CreateTracker
-> ReadPrec [CreateTracker]
-> Read CreateTracker
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [CreateTracker]
$creadListPrec :: ReadPrec [CreateTracker]
readPrec :: ReadPrec CreateTracker
$creadPrec :: ReadPrec CreateTracker
readList :: ReadS [CreateTracker]
$creadList :: ReadS [CreateTracker]
readsPrec :: Int -> ReadS CreateTracker
$creadsPrec :: Int -> ReadS CreateTracker
Prelude.Read, Int -> CreateTracker -> ShowS
[CreateTracker] -> ShowS
CreateTracker -> String
(Int -> CreateTracker -> ShowS)
-> (CreateTracker -> String)
-> ([CreateTracker] -> ShowS)
-> Show CreateTracker
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [CreateTracker] -> ShowS
$cshowList :: [CreateTracker] -> ShowS
show :: CreateTracker -> String
$cshow :: CreateTracker -> String
showsPrec :: Int -> CreateTracker -> ShowS
$cshowsPrec :: Int -> CreateTracker -> ShowS
Prelude.Show, (forall x. CreateTracker -> Rep CreateTracker x)
-> (forall x. Rep CreateTracker x -> CreateTracker)
-> Generic CreateTracker
forall x. Rep CreateTracker x -> CreateTracker
forall x. CreateTracker -> Rep CreateTracker x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep CreateTracker x -> CreateTracker
$cfrom :: forall x. CreateTracker -> Rep CreateTracker x
Prelude.Generic)
newCreateTracker ::
PricingPlan ->
Prelude.Text ->
CreateTracker
newCreateTracker :: PricingPlan -> Text -> CreateTracker
newCreateTracker PricingPlan
pPricingPlan_ Text
pTrackerName_ =
CreateTracker' :: Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe (HashMap Text Text)
-> Maybe PositionFiltering
-> PricingPlan
-> Text
-> CreateTracker
CreateTracker'
{ $sel:pricingPlanDataSource:CreateTracker' :: Maybe Text
pricingPlanDataSource =
Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:kmsKeyId:CreateTracker' :: Maybe Text
kmsKeyId = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:description:CreateTracker' :: Maybe Text
description = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:tags:CreateTracker' :: Maybe (HashMap Text Text)
tags = Maybe (HashMap Text Text)
forall a. Maybe a
Prelude.Nothing,
$sel:positionFiltering:CreateTracker' :: Maybe PositionFiltering
positionFiltering = Maybe PositionFiltering
forall a. Maybe a
Prelude.Nothing,
$sel:pricingPlan:CreateTracker' :: PricingPlan
pricingPlan = PricingPlan
pPricingPlan_,
$sel:trackerName:CreateTracker' :: Text
trackerName = Text
pTrackerName_
}
createTracker_pricingPlanDataSource :: Lens.Lens' CreateTracker (Prelude.Maybe Prelude.Text)
createTracker_pricingPlanDataSource :: (Maybe Text -> f (Maybe Text)) -> CreateTracker -> f CreateTracker
createTracker_pricingPlanDataSource = (CreateTracker -> Maybe Text)
-> (CreateTracker -> Maybe Text -> CreateTracker)
-> Lens CreateTracker CreateTracker (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateTracker' {Maybe Text
pricingPlanDataSource :: Maybe Text
$sel:pricingPlanDataSource:CreateTracker' :: CreateTracker -> Maybe Text
pricingPlanDataSource} -> Maybe Text
pricingPlanDataSource) (\s :: CreateTracker
s@CreateTracker' {} Maybe Text
a -> CreateTracker
s {$sel:pricingPlanDataSource:CreateTracker' :: Maybe Text
pricingPlanDataSource = Maybe Text
a} :: CreateTracker)
createTracker_kmsKeyId :: Lens.Lens' CreateTracker (Prelude.Maybe Prelude.Text)
createTracker_kmsKeyId :: (Maybe Text -> f (Maybe Text)) -> CreateTracker -> f CreateTracker
createTracker_kmsKeyId = (CreateTracker -> Maybe Text)
-> (CreateTracker -> Maybe Text -> CreateTracker)
-> Lens CreateTracker CreateTracker (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateTracker' {Maybe Text
kmsKeyId :: Maybe Text
$sel:kmsKeyId:CreateTracker' :: CreateTracker -> Maybe Text
kmsKeyId} -> Maybe Text
kmsKeyId) (\s :: CreateTracker
s@CreateTracker' {} Maybe Text
a -> CreateTracker
s {$sel:kmsKeyId:CreateTracker' :: Maybe Text
kmsKeyId = Maybe Text
a} :: CreateTracker)
createTracker_description :: Lens.Lens' CreateTracker (Prelude.Maybe Prelude.Text)
createTracker_description :: (Maybe Text -> f (Maybe Text)) -> CreateTracker -> f CreateTracker
createTracker_description = (CreateTracker -> Maybe Text)
-> (CreateTracker -> Maybe Text -> CreateTracker)
-> Lens CreateTracker CreateTracker (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateTracker' {Maybe Text
description :: Maybe Text
$sel:description:CreateTracker' :: CreateTracker -> Maybe Text
description} -> Maybe Text
description) (\s :: CreateTracker
s@CreateTracker' {} Maybe Text
a -> CreateTracker
s {$sel:description:CreateTracker' :: Maybe Text
description = Maybe Text
a} :: CreateTracker)
createTracker_tags :: Lens.Lens' CreateTracker (Prelude.Maybe (Prelude.HashMap Prelude.Text Prelude.Text))
createTracker_tags :: (Maybe (HashMap Text Text) -> f (Maybe (HashMap Text Text)))
-> CreateTracker -> f CreateTracker
createTracker_tags = (CreateTracker -> Maybe (HashMap Text Text))
-> (CreateTracker -> Maybe (HashMap Text Text) -> CreateTracker)
-> Lens
CreateTracker
CreateTracker
(Maybe (HashMap Text Text))
(Maybe (HashMap Text Text))
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateTracker' {Maybe (HashMap Text Text)
tags :: Maybe (HashMap Text Text)
$sel:tags:CreateTracker' :: CreateTracker -> Maybe (HashMap Text Text)
tags} -> Maybe (HashMap Text Text)
tags) (\s :: CreateTracker
s@CreateTracker' {} Maybe (HashMap Text Text)
a -> CreateTracker
s {$sel:tags:CreateTracker' :: Maybe (HashMap Text Text)
tags = Maybe (HashMap Text Text)
a} :: CreateTracker) ((Maybe (HashMap Text Text) -> f (Maybe (HashMap Text Text)))
-> CreateTracker -> f CreateTracker)
-> ((Maybe (HashMap Text Text) -> f (Maybe (HashMap Text Text)))
-> Maybe (HashMap Text Text) -> f (Maybe (HashMap Text Text)))
-> (Maybe (HashMap Text Text) -> f (Maybe (HashMap Text Text)))
-> CreateTracker
-> f CreateTracker
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso
(HashMap Text Text)
(HashMap Text Text)
(HashMap Text Text)
(HashMap Text Text)
-> Iso
(Maybe (HashMap Text Text))
(Maybe (HashMap Text Text))
(Maybe (HashMap Text Text))
(Maybe (HashMap Text 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
(HashMap Text Text)
(HashMap Text Text)
(HashMap Text Text)
(HashMap Text Text)
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced
createTracker_positionFiltering :: Lens.Lens' CreateTracker (Prelude.Maybe PositionFiltering)
createTracker_positionFiltering :: (Maybe PositionFiltering -> f (Maybe PositionFiltering))
-> CreateTracker -> f CreateTracker
createTracker_positionFiltering = (CreateTracker -> Maybe PositionFiltering)
-> (CreateTracker -> Maybe PositionFiltering -> CreateTracker)
-> Lens
CreateTracker
CreateTracker
(Maybe PositionFiltering)
(Maybe PositionFiltering)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateTracker' {Maybe PositionFiltering
positionFiltering :: Maybe PositionFiltering
$sel:positionFiltering:CreateTracker' :: CreateTracker -> Maybe PositionFiltering
positionFiltering} -> Maybe PositionFiltering
positionFiltering) (\s :: CreateTracker
s@CreateTracker' {} Maybe PositionFiltering
a -> CreateTracker
s {$sel:positionFiltering:CreateTracker' :: Maybe PositionFiltering
positionFiltering = Maybe PositionFiltering
a} :: CreateTracker)
createTracker_pricingPlan :: Lens.Lens' CreateTracker PricingPlan
createTracker_pricingPlan :: (PricingPlan -> f PricingPlan) -> CreateTracker -> f CreateTracker
createTracker_pricingPlan = (CreateTracker -> PricingPlan)
-> (CreateTracker -> PricingPlan -> CreateTracker)
-> Lens CreateTracker CreateTracker PricingPlan PricingPlan
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateTracker' {PricingPlan
pricingPlan :: PricingPlan
$sel:pricingPlan:CreateTracker' :: CreateTracker -> PricingPlan
pricingPlan} -> PricingPlan
pricingPlan) (\s :: CreateTracker
s@CreateTracker' {} PricingPlan
a -> CreateTracker
s {$sel:pricingPlan:CreateTracker' :: PricingPlan
pricingPlan = PricingPlan
a} :: CreateTracker)
createTracker_trackerName :: Lens.Lens' CreateTracker Prelude.Text
createTracker_trackerName :: (Text -> f Text) -> CreateTracker -> f CreateTracker
createTracker_trackerName = (CreateTracker -> Text)
-> (CreateTracker -> Text -> CreateTracker)
-> Lens CreateTracker CreateTracker Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateTracker' {Text
trackerName :: Text
$sel:trackerName:CreateTracker' :: CreateTracker -> Text
trackerName} -> Text
trackerName) (\s :: CreateTracker
s@CreateTracker' {} Text
a -> CreateTracker
s {$sel:trackerName:CreateTracker' :: Text
trackerName = Text
a} :: CreateTracker)
instance Core.AWSRequest CreateTracker where
type
AWSResponse CreateTracker =
CreateTrackerResponse
request :: CreateTracker -> Request CreateTracker
request = Service -> CreateTracker -> Request CreateTracker
forall a. (ToRequest a, ToJSON a) => Service -> a -> Request a
Request.postJSON Service
defaultService
response :: Logger
-> Service
-> Proxy CreateTracker
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse CreateTracker)))
response =
(Int
-> ResponseHeaders
-> Object
-> Either String (AWSResponse CreateTracker))
-> Logger
-> Service
-> Proxy CreateTracker
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse CreateTracker)))
forall (m :: * -> *) a.
MonadResource m =>
(Int -> ResponseHeaders -> Object -> Either String (AWSResponse a))
-> Logger
-> Service
-> Proxy a
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse a)))
Response.receiveJSON
( \Int
s ResponseHeaders
h Object
x ->
Int -> POSIX -> Text -> Text -> CreateTrackerResponse
CreateTrackerResponse'
(Int -> POSIX -> Text -> Text -> CreateTrackerResponse)
-> Either String Int
-> Either String (POSIX -> Text -> Text -> CreateTrackerResponse)
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))
Either String (POSIX -> Text -> Text -> CreateTrackerResponse)
-> Either String POSIX
-> Either String (Text -> Text -> CreateTrackerResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Either String POSIX
forall a. FromJSON a => Object -> Text -> Either String a
Core..:> Text
"CreateTime")
Either String (Text -> Text -> CreateTrackerResponse)
-> Either String Text
-> Either String (Text -> CreateTrackerResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Either String Text
forall a. FromJSON a => Object -> Text -> Either String a
Core..:> Text
"TrackerArn")
Either String (Text -> CreateTrackerResponse)
-> Either String Text -> Either String CreateTrackerResponse
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Either String Text
forall a. FromJSON a => Object -> Text -> Either String a
Core..:> Text
"TrackerName")
)
instance Prelude.Hashable CreateTracker
instance Prelude.NFData CreateTracker
instance Core.ToHeaders CreateTracker where
toHeaders :: CreateTracker -> ResponseHeaders
toHeaders =
ResponseHeaders -> CreateTracker -> ResponseHeaders
forall a b. a -> b -> a
Prelude.const
( [ResponseHeaders] -> ResponseHeaders
forall a. Monoid a => [a] -> a
Prelude.mconcat
[ 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 CreateTracker where
toJSON :: CreateTracker -> Value
toJSON CreateTracker' {Maybe Text
Maybe (HashMap Text Text)
Maybe PositionFiltering
Text
PricingPlan
trackerName :: Text
pricingPlan :: PricingPlan
positionFiltering :: Maybe PositionFiltering
tags :: Maybe (HashMap Text Text)
description :: Maybe Text
kmsKeyId :: Maybe Text
pricingPlanDataSource :: Maybe Text
$sel:trackerName:CreateTracker' :: CreateTracker -> Text
$sel:pricingPlan:CreateTracker' :: CreateTracker -> PricingPlan
$sel:positionFiltering:CreateTracker' :: CreateTracker -> Maybe PositionFiltering
$sel:tags:CreateTracker' :: CreateTracker -> Maybe (HashMap Text Text)
$sel:description:CreateTracker' :: CreateTracker -> Maybe Text
$sel:kmsKeyId:CreateTracker' :: CreateTracker -> Maybe Text
$sel:pricingPlanDataSource:CreateTracker' :: CreateTracker -> Maybe Text
..} =
[Pair] -> Value
Core.object
( [Maybe Pair] -> [Pair]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
[ (Text
"PricingPlanDataSource" 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
pricingPlanDataSource,
(Text
"KmsKeyId" 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
kmsKeyId,
(Text
"Description" 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
description,
(Text
"Tags" Text -> HashMap Text Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (HashMap Text Text -> Pair)
-> Maybe (HashMap Text Text) -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (HashMap Text Text)
tags,
(Text
"PositionFiltering" Text -> PositionFiltering -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
(PositionFiltering -> Pair)
-> Maybe PositionFiltering -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe PositionFiltering
positionFiltering,
Pair -> Maybe Pair
forall a. a -> Maybe a
Prelude.Just (Text
"PricingPlan" Text -> PricingPlan -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..= PricingPlan
pricingPlan),
Pair -> Maybe Pair
forall a. a -> Maybe a
Prelude.Just (Text
"TrackerName" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..= Text
trackerName)
]
)
instance Core.ToPath CreateTracker where
toPath :: CreateTracker -> ByteString
toPath = ByteString -> CreateTracker -> ByteString
forall a b. a -> b -> a
Prelude.const ByteString
"/tracking/v0/trackers"
instance Core.ToQuery CreateTracker where
toQuery :: CreateTracker -> QueryString
toQuery = QueryString -> CreateTracker -> QueryString
forall a b. a -> b -> a
Prelude.const QueryString
forall a. Monoid a => a
Prelude.mempty
data CreateTrackerResponse = CreateTrackerResponse'
{
CreateTrackerResponse -> Int
httpStatus :: Prelude.Int,
CreateTrackerResponse -> POSIX
createTime :: Core.POSIX,
CreateTrackerResponse -> Text
trackerArn :: Prelude.Text,
CreateTrackerResponse -> Text
trackerName :: Prelude.Text
}
deriving (CreateTrackerResponse -> CreateTrackerResponse -> Bool
(CreateTrackerResponse -> CreateTrackerResponse -> Bool)
-> (CreateTrackerResponse -> CreateTrackerResponse -> Bool)
-> Eq CreateTrackerResponse
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: CreateTrackerResponse -> CreateTrackerResponse -> Bool
$c/= :: CreateTrackerResponse -> CreateTrackerResponse -> Bool
== :: CreateTrackerResponse -> CreateTrackerResponse -> Bool
$c== :: CreateTrackerResponse -> CreateTrackerResponse -> Bool
Prelude.Eq, ReadPrec [CreateTrackerResponse]
ReadPrec CreateTrackerResponse
Int -> ReadS CreateTrackerResponse
ReadS [CreateTrackerResponse]
(Int -> ReadS CreateTrackerResponse)
-> ReadS [CreateTrackerResponse]
-> ReadPrec CreateTrackerResponse
-> ReadPrec [CreateTrackerResponse]
-> Read CreateTrackerResponse
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [CreateTrackerResponse]
$creadListPrec :: ReadPrec [CreateTrackerResponse]
readPrec :: ReadPrec CreateTrackerResponse
$creadPrec :: ReadPrec CreateTrackerResponse
readList :: ReadS [CreateTrackerResponse]
$creadList :: ReadS [CreateTrackerResponse]
readsPrec :: Int -> ReadS CreateTrackerResponse
$creadsPrec :: Int -> ReadS CreateTrackerResponse
Prelude.Read, Int -> CreateTrackerResponse -> ShowS
[CreateTrackerResponse] -> ShowS
CreateTrackerResponse -> String
(Int -> CreateTrackerResponse -> ShowS)
-> (CreateTrackerResponse -> String)
-> ([CreateTrackerResponse] -> ShowS)
-> Show CreateTrackerResponse
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [CreateTrackerResponse] -> ShowS
$cshowList :: [CreateTrackerResponse] -> ShowS
show :: CreateTrackerResponse -> String
$cshow :: CreateTrackerResponse -> String
showsPrec :: Int -> CreateTrackerResponse -> ShowS
$cshowsPrec :: Int -> CreateTrackerResponse -> ShowS
Prelude.Show, (forall x. CreateTrackerResponse -> Rep CreateTrackerResponse x)
-> (forall x. Rep CreateTrackerResponse x -> CreateTrackerResponse)
-> Generic CreateTrackerResponse
forall x. Rep CreateTrackerResponse x -> CreateTrackerResponse
forall x. CreateTrackerResponse -> Rep CreateTrackerResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep CreateTrackerResponse x -> CreateTrackerResponse
$cfrom :: forall x. CreateTrackerResponse -> Rep CreateTrackerResponse x
Prelude.Generic)
newCreateTrackerResponse ::
Prelude.Int ->
Prelude.UTCTime ->
Prelude.Text ->
Prelude.Text ->
CreateTrackerResponse
newCreateTrackerResponse :: Int -> UTCTime -> Text -> Text -> CreateTrackerResponse
newCreateTrackerResponse
Int
pHttpStatus_
UTCTime
pCreateTime_
Text
pTrackerArn_
Text
pTrackerName_ =
CreateTrackerResponse' :: Int -> POSIX -> Text -> Text -> CreateTrackerResponse
CreateTrackerResponse'
{ $sel:httpStatus:CreateTrackerResponse' :: Int
httpStatus = Int
pHttpStatus_,
$sel:createTime:CreateTrackerResponse' :: 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:trackerArn:CreateTrackerResponse' :: Text
trackerArn = Text
pTrackerArn_,
$sel:trackerName:CreateTrackerResponse' :: Text
trackerName = Text
pTrackerName_
}
createTrackerResponse_httpStatus :: Lens.Lens' CreateTrackerResponse Prelude.Int
createTrackerResponse_httpStatus :: (Int -> f Int) -> CreateTrackerResponse -> f CreateTrackerResponse
createTrackerResponse_httpStatus = (CreateTrackerResponse -> Int)
-> (CreateTrackerResponse -> Int -> CreateTrackerResponse)
-> Lens CreateTrackerResponse CreateTrackerResponse Int Int
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateTrackerResponse' {Int
httpStatus :: Int
$sel:httpStatus:CreateTrackerResponse' :: CreateTrackerResponse -> Int
httpStatus} -> Int
httpStatus) (\s :: CreateTrackerResponse
s@CreateTrackerResponse' {} Int
a -> CreateTrackerResponse
s {$sel:httpStatus:CreateTrackerResponse' :: Int
httpStatus = Int
a} :: CreateTrackerResponse)
createTrackerResponse_createTime :: Lens.Lens' CreateTrackerResponse Prelude.UTCTime
createTrackerResponse_createTime :: (UTCTime -> f UTCTime)
-> CreateTrackerResponse -> f CreateTrackerResponse
createTrackerResponse_createTime = (CreateTrackerResponse -> POSIX)
-> (CreateTrackerResponse -> POSIX -> CreateTrackerResponse)
-> Lens CreateTrackerResponse CreateTrackerResponse POSIX POSIX
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateTrackerResponse' {POSIX
createTime :: POSIX
$sel:createTime:CreateTrackerResponse' :: CreateTrackerResponse -> POSIX
createTime} -> POSIX
createTime) (\s :: CreateTrackerResponse
s@CreateTrackerResponse' {} POSIX
a -> CreateTrackerResponse
s {$sel:createTime:CreateTrackerResponse' :: POSIX
createTime = POSIX
a} :: CreateTrackerResponse) ((POSIX -> f POSIX)
-> CreateTrackerResponse -> f CreateTrackerResponse)
-> ((UTCTime -> f UTCTime) -> POSIX -> f POSIX)
-> (UTCTime -> f UTCTime)
-> CreateTrackerResponse
-> f CreateTrackerResponse
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
createTrackerResponse_trackerArn :: Lens.Lens' CreateTrackerResponse Prelude.Text
createTrackerResponse_trackerArn :: (Text -> f Text)
-> CreateTrackerResponse -> f CreateTrackerResponse
createTrackerResponse_trackerArn = (CreateTrackerResponse -> Text)
-> (CreateTrackerResponse -> Text -> CreateTrackerResponse)
-> Lens CreateTrackerResponse CreateTrackerResponse Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateTrackerResponse' {Text
trackerArn :: Text
$sel:trackerArn:CreateTrackerResponse' :: CreateTrackerResponse -> Text
trackerArn} -> Text
trackerArn) (\s :: CreateTrackerResponse
s@CreateTrackerResponse' {} Text
a -> CreateTrackerResponse
s {$sel:trackerArn:CreateTrackerResponse' :: Text
trackerArn = Text
a} :: CreateTrackerResponse)
createTrackerResponse_trackerName :: Lens.Lens' CreateTrackerResponse Prelude.Text
createTrackerResponse_trackerName :: (Text -> f Text)
-> CreateTrackerResponse -> f CreateTrackerResponse
createTrackerResponse_trackerName = (CreateTrackerResponse -> Text)
-> (CreateTrackerResponse -> Text -> CreateTrackerResponse)
-> Lens CreateTrackerResponse CreateTrackerResponse Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateTrackerResponse' {Text
trackerName :: Text
$sel:trackerName:CreateTrackerResponse' :: CreateTrackerResponse -> Text
trackerName} -> Text
trackerName) (\s :: CreateTrackerResponse
s@CreateTrackerResponse' {} Text
a -> CreateTrackerResponse
s {$sel:trackerName:CreateTrackerResponse' :: Text
trackerName = Text
a} :: CreateTrackerResponse)
instance Prelude.NFData CreateTrackerResponse