{-# 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.Synthetics.Types.CanaryRunConfigOutput where
import qualified Amazonka.Core as Core
import qualified Amazonka.Core.Lens.Internal as Lens
import qualified Amazonka.Data as Data
import qualified Amazonka.Prelude as Prelude
data CanaryRunConfigOutput = CanaryRunConfigOutput'
{
CanaryRunConfigOutput -> Maybe Bool
activeTracing :: Prelude.Maybe Prelude.Bool,
CanaryRunConfigOutput -> Maybe Natural
memoryInMB :: Prelude.Maybe Prelude.Natural,
CanaryRunConfigOutput -> Maybe Natural
timeoutInSeconds :: Prelude.Maybe Prelude.Natural
}
deriving (CanaryRunConfigOutput -> CanaryRunConfigOutput -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: CanaryRunConfigOutput -> CanaryRunConfigOutput -> Bool
$c/= :: CanaryRunConfigOutput -> CanaryRunConfigOutput -> Bool
== :: CanaryRunConfigOutput -> CanaryRunConfigOutput -> Bool
$c== :: CanaryRunConfigOutput -> CanaryRunConfigOutput -> Bool
Prelude.Eq, ReadPrec [CanaryRunConfigOutput]
ReadPrec CanaryRunConfigOutput
Int -> ReadS CanaryRunConfigOutput
ReadS [CanaryRunConfigOutput]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [CanaryRunConfigOutput]
$creadListPrec :: ReadPrec [CanaryRunConfigOutput]
readPrec :: ReadPrec CanaryRunConfigOutput
$creadPrec :: ReadPrec CanaryRunConfigOutput
readList :: ReadS [CanaryRunConfigOutput]
$creadList :: ReadS [CanaryRunConfigOutput]
readsPrec :: Int -> ReadS CanaryRunConfigOutput
$creadsPrec :: Int -> ReadS CanaryRunConfigOutput
Prelude.Read, Int -> CanaryRunConfigOutput -> ShowS
[CanaryRunConfigOutput] -> ShowS
CanaryRunConfigOutput -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [CanaryRunConfigOutput] -> ShowS
$cshowList :: [CanaryRunConfigOutput] -> ShowS
show :: CanaryRunConfigOutput -> String
$cshow :: CanaryRunConfigOutput -> String
showsPrec :: Int -> CanaryRunConfigOutput -> ShowS
$cshowsPrec :: Int -> CanaryRunConfigOutput -> ShowS
Prelude.Show, forall x. Rep CanaryRunConfigOutput x -> CanaryRunConfigOutput
forall x. CanaryRunConfigOutput -> Rep CanaryRunConfigOutput x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep CanaryRunConfigOutput x -> CanaryRunConfigOutput
$cfrom :: forall x. CanaryRunConfigOutput -> Rep CanaryRunConfigOutput x
Prelude.Generic)
newCanaryRunConfigOutput ::
CanaryRunConfigOutput
newCanaryRunConfigOutput :: CanaryRunConfigOutput
newCanaryRunConfigOutput =
CanaryRunConfigOutput'
{ $sel:activeTracing:CanaryRunConfigOutput' :: Maybe Bool
activeTracing =
forall a. Maybe a
Prelude.Nothing,
$sel:memoryInMB:CanaryRunConfigOutput' :: Maybe Natural
memoryInMB = forall a. Maybe a
Prelude.Nothing,
$sel:timeoutInSeconds:CanaryRunConfigOutput' :: Maybe Natural
timeoutInSeconds = forall a. Maybe a
Prelude.Nothing
}
canaryRunConfigOutput_activeTracing :: Lens.Lens' CanaryRunConfigOutput (Prelude.Maybe Prelude.Bool)
canaryRunConfigOutput_activeTracing :: Lens' CanaryRunConfigOutput (Maybe Bool)
canaryRunConfigOutput_activeTracing = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CanaryRunConfigOutput' {Maybe Bool
activeTracing :: Maybe Bool
$sel:activeTracing:CanaryRunConfigOutput' :: CanaryRunConfigOutput -> Maybe Bool
activeTracing} -> Maybe Bool
activeTracing) (\s :: CanaryRunConfigOutput
s@CanaryRunConfigOutput' {} Maybe Bool
a -> CanaryRunConfigOutput
s {$sel:activeTracing:CanaryRunConfigOutput' :: Maybe Bool
activeTracing = Maybe Bool
a} :: CanaryRunConfigOutput)
canaryRunConfigOutput_memoryInMB :: Lens.Lens' CanaryRunConfigOutput (Prelude.Maybe Prelude.Natural)
canaryRunConfigOutput_memoryInMB :: Lens' CanaryRunConfigOutput (Maybe Natural)
canaryRunConfigOutput_memoryInMB = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CanaryRunConfigOutput' {Maybe Natural
memoryInMB :: Maybe Natural
$sel:memoryInMB:CanaryRunConfigOutput' :: CanaryRunConfigOutput -> Maybe Natural
memoryInMB} -> Maybe Natural
memoryInMB) (\s :: CanaryRunConfigOutput
s@CanaryRunConfigOutput' {} Maybe Natural
a -> CanaryRunConfigOutput
s {$sel:memoryInMB:CanaryRunConfigOutput' :: Maybe Natural
memoryInMB = Maybe Natural
a} :: CanaryRunConfigOutput)
canaryRunConfigOutput_timeoutInSeconds :: Lens.Lens' CanaryRunConfigOutput (Prelude.Maybe Prelude.Natural)
canaryRunConfigOutput_timeoutInSeconds :: Lens' CanaryRunConfigOutput (Maybe Natural)
canaryRunConfigOutput_timeoutInSeconds = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CanaryRunConfigOutput' {Maybe Natural
timeoutInSeconds :: Maybe Natural
$sel:timeoutInSeconds:CanaryRunConfigOutput' :: CanaryRunConfigOutput -> Maybe Natural
timeoutInSeconds} -> Maybe Natural
timeoutInSeconds) (\s :: CanaryRunConfigOutput
s@CanaryRunConfigOutput' {} Maybe Natural
a -> CanaryRunConfigOutput
s {$sel:timeoutInSeconds:CanaryRunConfigOutput' :: Maybe Natural
timeoutInSeconds = Maybe Natural
a} :: CanaryRunConfigOutput)
instance Data.FromJSON CanaryRunConfigOutput where
parseJSON :: Value -> Parser CanaryRunConfigOutput
parseJSON =
forall a. String -> (Object -> Parser a) -> Value -> Parser a
Data.withObject
String
"CanaryRunConfigOutput"
( \Object
x ->
Maybe Bool
-> Maybe Natural -> Maybe Natural -> CanaryRunConfigOutput
CanaryRunConfigOutput'
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
"ActiveTracing")
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"MemoryInMB")
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"TimeoutInSeconds")
)
instance Prelude.Hashable CanaryRunConfigOutput where
hashWithSalt :: Int -> CanaryRunConfigOutput -> Int
hashWithSalt Int
_salt CanaryRunConfigOutput' {Maybe Bool
Maybe Natural
timeoutInSeconds :: Maybe Natural
memoryInMB :: Maybe Natural
activeTracing :: Maybe Bool
$sel:timeoutInSeconds:CanaryRunConfigOutput' :: CanaryRunConfigOutput -> Maybe Natural
$sel:memoryInMB:CanaryRunConfigOutput' :: CanaryRunConfigOutput -> Maybe Natural
$sel:activeTracing:CanaryRunConfigOutput' :: CanaryRunConfigOutput -> Maybe Bool
..} =
Int
_salt
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Bool
activeTracing
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Natural
memoryInMB
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Natural
timeoutInSeconds
instance Prelude.NFData CanaryRunConfigOutput where
rnf :: CanaryRunConfigOutput -> ()
rnf CanaryRunConfigOutput' {Maybe Bool
Maybe Natural
timeoutInSeconds :: Maybe Natural
memoryInMB :: Maybe Natural
activeTracing :: Maybe Bool
$sel:timeoutInSeconds:CanaryRunConfigOutput' :: CanaryRunConfigOutput -> Maybe Natural
$sel:memoryInMB:CanaryRunConfigOutput' :: CanaryRunConfigOutput -> Maybe Natural
$sel:activeTracing:CanaryRunConfigOutput' :: CanaryRunConfigOutput -> Maybe Bool
..} =
forall a. NFData a => a -> ()
Prelude.rnf Maybe Bool
activeTracing
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Natural
memoryInMB
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Natural
timeoutInSeconds