{-# 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.CloudFormation.Types.StackDriftInformationSummary where
import Amazonka.CloudFormation.Types.StackDriftStatus
import qualified Amazonka.Core as Core
import qualified Amazonka.Lens as Lens
import qualified Amazonka.Prelude as Prelude
data StackDriftInformationSummary = StackDriftInformationSummary'
{
StackDriftInformationSummary -> Maybe ISO8601
lastCheckTimestamp :: Prelude.Maybe Core.ISO8601,
StackDriftInformationSummary -> StackDriftStatus
stackDriftStatus :: StackDriftStatus
}
deriving (StackDriftInformationSummary
-> StackDriftInformationSummary -> Bool
(StackDriftInformationSummary
-> StackDriftInformationSummary -> Bool)
-> (StackDriftInformationSummary
-> StackDriftInformationSummary -> Bool)
-> Eq StackDriftInformationSummary
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: StackDriftInformationSummary
-> StackDriftInformationSummary -> Bool
$c/= :: StackDriftInformationSummary
-> StackDriftInformationSummary -> Bool
== :: StackDriftInformationSummary
-> StackDriftInformationSummary -> Bool
$c== :: StackDriftInformationSummary
-> StackDriftInformationSummary -> Bool
Prelude.Eq, ReadPrec [StackDriftInformationSummary]
ReadPrec StackDriftInformationSummary
Int -> ReadS StackDriftInformationSummary
ReadS [StackDriftInformationSummary]
(Int -> ReadS StackDriftInformationSummary)
-> ReadS [StackDriftInformationSummary]
-> ReadPrec StackDriftInformationSummary
-> ReadPrec [StackDriftInformationSummary]
-> Read StackDriftInformationSummary
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [StackDriftInformationSummary]
$creadListPrec :: ReadPrec [StackDriftInformationSummary]
readPrec :: ReadPrec StackDriftInformationSummary
$creadPrec :: ReadPrec StackDriftInformationSummary
readList :: ReadS [StackDriftInformationSummary]
$creadList :: ReadS [StackDriftInformationSummary]
readsPrec :: Int -> ReadS StackDriftInformationSummary
$creadsPrec :: Int -> ReadS StackDriftInformationSummary
Prelude.Read, Int -> StackDriftInformationSummary -> ShowS
[StackDriftInformationSummary] -> ShowS
StackDriftInformationSummary -> String
(Int -> StackDriftInformationSummary -> ShowS)
-> (StackDriftInformationSummary -> String)
-> ([StackDriftInformationSummary] -> ShowS)
-> Show StackDriftInformationSummary
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [StackDriftInformationSummary] -> ShowS
$cshowList :: [StackDriftInformationSummary] -> ShowS
show :: StackDriftInformationSummary -> String
$cshow :: StackDriftInformationSummary -> String
showsPrec :: Int -> StackDriftInformationSummary -> ShowS
$cshowsPrec :: Int -> StackDriftInformationSummary -> ShowS
Prelude.Show, (forall x.
StackDriftInformationSummary -> Rep StackDriftInformationSummary x)
-> (forall x.
Rep StackDriftInformationSummary x -> StackDriftInformationSummary)
-> Generic StackDriftInformationSummary
forall x.
Rep StackDriftInformationSummary x -> StackDriftInformationSummary
forall x.
StackDriftInformationSummary -> Rep StackDriftInformationSummary x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep StackDriftInformationSummary x -> StackDriftInformationSummary
$cfrom :: forall x.
StackDriftInformationSummary -> Rep StackDriftInformationSummary x
Prelude.Generic)
newStackDriftInformationSummary ::
StackDriftStatus ->
StackDriftInformationSummary
newStackDriftInformationSummary :: StackDriftStatus -> StackDriftInformationSummary
newStackDriftInformationSummary StackDriftStatus
pStackDriftStatus_ =
StackDriftInformationSummary' :: Maybe ISO8601 -> StackDriftStatus -> StackDriftInformationSummary
StackDriftInformationSummary'
{ $sel:lastCheckTimestamp:StackDriftInformationSummary' :: Maybe ISO8601
lastCheckTimestamp =
Maybe ISO8601
forall a. Maybe a
Prelude.Nothing,
$sel:stackDriftStatus:StackDriftInformationSummary' :: StackDriftStatus
stackDriftStatus = StackDriftStatus
pStackDriftStatus_
}
stackDriftInformationSummary_lastCheckTimestamp :: Lens.Lens' StackDriftInformationSummary (Prelude.Maybe Prelude.UTCTime)
stackDriftInformationSummary_lastCheckTimestamp :: (Maybe UTCTime -> f (Maybe UTCTime))
-> StackDriftInformationSummary -> f StackDriftInformationSummary
stackDriftInformationSummary_lastCheckTimestamp = (StackDriftInformationSummary -> Maybe ISO8601)
-> (StackDriftInformationSummary
-> Maybe ISO8601 -> StackDriftInformationSummary)
-> Lens
StackDriftInformationSummary
StackDriftInformationSummary
(Maybe ISO8601)
(Maybe ISO8601)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\StackDriftInformationSummary' {Maybe ISO8601
lastCheckTimestamp :: Maybe ISO8601
$sel:lastCheckTimestamp:StackDriftInformationSummary' :: StackDriftInformationSummary -> Maybe ISO8601
lastCheckTimestamp} -> Maybe ISO8601
lastCheckTimestamp) (\s :: StackDriftInformationSummary
s@StackDriftInformationSummary' {} Maybe ISO8601
a -> StackDriftInformationSummary
s {$sel:lastCheckTimestamp:StackDriftInformationSummary' :: Maybe ISO8601
lastCheckTimestamp = Maybe ISO8601
a} :: StackDriftInformationSummary) ((Maybe ISO8601 -> f (Maybe ISO8601))
-> StackDriftInformationSummary -> f StackDriftInformationSummary)
-> ((Maybe UTCTime -> f (Maybe UTCTime))
-> Maybe ISO8601 -> f (Maybe ISO8601))
-> (Maybe UTCTime -> f (Maybe UTCTime))
-> StackDriftInformationSummary
-> f StackDriftInformationSummary
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso ISO8601 ISO8601 UTCTime UTCTime
-> Iso
(Maybe ISO8601) (Maybe ISO8601) (Maybe UTCTime) (Maybe UTCTime)
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 ISO8601 ISO8601 UTCTime UTCTime
forall (a :: Format). Iso' (Time a) UTCTime
Core._Time
stackDriftInformationSummary_stackDriftStatus :: Lens.Lens' StackDriftInformationSummary StackDriftStatus
stackDriftInformationSummary_stackDriftStatus :: (StackDriftStatus -> f StackDriftStatus)
-> StackDriftInformationSummary -> f StackDriftInformationSummary
stackDriftInformationSummary_stackDriftStatus = (StackDriftInformationSummary -> StackDriftStatus)
-> (StackDriftInformationSummary
-> StackDriftStatus -> StackDriftInformationSummary)
-> Lens
StackDriftInformationSummary
StackDriftInformationSummary
StackDriftStatus
StackDriftStatus
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\StackDriftInformationSummary' {StackDriftStatus
stackDriftStatus :: StackDriftStatus
$sel:stackDriftStatus:StackDriftInformationSummary' :: StackDriftInformationSummary -> StackDriftStatus
stackDriftStatus} -> StackDriftStatus
stackDriftStatus) (\s :: StackDriftInformationSummary
s@StackDriftInformationSummary' {} StackDriftStatus
a -> StackDriftInformationSummary
s {$sel:stackDriftStatus:StackDriftInformationSummary' :: StackDriftStatus
stackDriftStatus = StackDriftStatus
a} :: StackDriftInformationSummary)
instance Core.FromXML StackDriftInformationSummary where
parseXML :: [Node] -> Either String StackDriftInformationSummary
parseXML [Node]
x =
Maybe ISO8601 -> StackDriftStatus -> StackDriftInformationSummary
StackDriftInformationSummary'
(Maybe ISO8601 -> StackDriftStatus -> StackDriftInformationSummary)
-> Either String (Maybe ISO8601)
-> Either String (StackDriftStatus -> StackDriftInformationSummary)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> ([Node]
x [Node] -> Text -> Either String (Maybe ISO8601)
forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Core..@? Text
"LastCheckTimestamp")
Either String (StackDriftStatus -> StackDriftInformationSummary)
-> Either String StackDriftStatus
-> Either String StackDriftInformationSummary
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ([Node]
x [Node] -> Text -> Either String StackDriftStatus
forall a. FromXML a => [Node] -> Text -> Either String a
Core..@ Text
"StackDriftStatus")
instance
Prelude.Hashable
StackDriftInformationSummary
instance Prelude.NFData StackDriftInformationSummary