{-# 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.StackSummary where
import Amazonka.CloudFormation.Types.StackDriftInformationSummary
import Amazonka.CloudFormation.Types.StackStatus
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 StackSummary = StackSummary'
{
StackSummary -> Maybe ISO8601
deletionTime :: Prelude.Maybe Data.ISO8601,
StackSummary -> Maybe StackDriftInformationSummary
driftInformation :: Prelude.Maybe StackDriftInformationSummary,
StackSummary -> Maybe ISO8601
lastUpdatedTime :: Prelude.Maybe Data.ISO8601,
StackSummary -> Maybe Text
parentId :: Prelude.Maybe Prelude.Text,
StackSummary -> Maybe Text
rootId :: Prelude.Maybe Prelude.Text,
StackSummary -> Maybe Text
stackId :: Prelude.Maybe Prelude.Text,
StackSummary -> Maybe Text
stackStatusReason :: Prelude.Maybe Prelude.Text,
StackSummary -> Maybe Text
templateDescription :: Prelude.Maybe Prelude.Text,
StackSummary -> Text
stackName :: Prelude.Text,
StackSummary -> ISO8601
creationTime :: Data.ISO8601,
StackSummary -> StackStatus
stackStatus :: StackStatus
}
deriving (StackSummary -> StackSummary -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: StackSummary -> StackSummary -> Bool
$c/= :: StackSummary -> StackSummary -> Bool
== :: StackSummary -> StackSummary -> Bool
$c== :: StackSummary -> StackSummary -> Bool
Prelude.Eq, ReadPrec [StackSummary]
ReadPrec StackSummary
Int -> ReadS StackSummary
ReadS [StackSummary]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [StackSummary]
$creadListPrec :: ReadPrec [StackSummary]
readPrec :: ReadPrec StackSummary
$creadPrec :: ReadPrec StackSummary
readList :: ReadS [StackSummary]
$creadList :: ReadS [StackSummary]
readsPrec :: Int -> ReadS StackSummary
$creadsPrec :: Int -> ReadS StackSummary
Prelude.Read, Int -> StackSummary -> ShowS
[StackSummary] -> ShowS
StackSummary -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [StackSummary] -> ShowS
$cshowList :: [StackSummary] -> ShowS
show :: StackSummary -> String
$cshow :: StackSummary -> String
showsPrec :: Int -> StackSummary -> ShowS
$cshowsPrec :: Int -> StackSummary -> ShowS
Prelude.Show, forall x. Rep StackSummary x -> StackSummary
forall x. StackSummary -> Rep StackSummary x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep StackSummary x -> StackSummary
$cfrom :: forall x. StackSummary -> Rep StackSummary x
Prelude.Generic)
newStackSummary ::
Prelude.Text ->
Prelude.UTCTime ->
StackStatus ->
StackSummary
newStackSummary :: Text -> UTCTime -> StackStatus -> StackSummary
newStackSummary
Text
pStackName_
UTCTime
pCreationTime_
StackStatus
pStackStatus_ =
StackSummary'
{ $sel:deletionTime:StackSummary' :: Maybe ISO8601
deletionTime = forall a. Maybe a
Prelude.Nothing,
$sel:driftInformation:StackSummary' :: Maybe StackDriftInformationSummary
driftInformation = forall a. Maybe a
Prelude.Nothing,
$sel:lastUpdatedTime:StackSummary' :: Maybe ISO8601
lastUpdatedTime = forall a. Maybe a
Prelude.Nothing,
$sel:parentId:StackSummary' :: Maybe Text
parentId = forall a. Maybe a
Prelude.Nothing,
$sel:rootId:StackSummary' :: Maybe Text
rootId = forall a. Maybe a
Prelude.Nothing,
$sel:stackId:StackSummary' :: Maybe Text
stackId = forall a. Maybe a
Prelude.Nothing,
$sel:stackStatusReason:StackSummary' :: Maybe Text
stackStatusReason = forall a. Maybe a
Prelude.Nothing,
$sel:templateDescription:StackSummary' :: Maybe Text
templateDescription = forall a. Maybe a
Prelude.Nothing,
$sel:stackName:StackSummary' :: Text
stackName = Text
pStackName_,
$sel:creationTime:StackSummary' :: ISO8601
creationTime = forall (a :: Format). Iso' (Time a) UTCTime
Data._Time forall t b. AReview t b -> b -> t
Lens.# UTCTime
pCreationTime_,
$sel:stackStatus:StackSummary' :: StackStatus
stackStatus = StackStatus
pStackStatus_
}
stackSummary_deletionTime :: Lens.Lens' StackSummary (Prelude.Maybe Prelude.UTCTime)
stackSummary_deletionTime :: Lens' StackSummary (Maybe UTCTime)
stackSummary_deletionTime = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\StackSummary' {Maybe ISO8601
deletionTime :: Maybe ISO8601
$sel:deletionTime:StackSummary' :: StackSummary -> Maybe ISO8601
deletionTime} -> Maybe ISO8601
deletionTime) (\s :: StackSummary
s@StackSummary' {} Maybe ISO8601
a -> StackSummary
s {$sel:deletionTime:StackSummary' :: Maybe ISO8601
deletionTime = Maybe ISO8601
a} :: StackSummary) forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. 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 forall (a :: Format). Iso' (Time a) UTCTime
Data._Time
stackSummary_driftInformation :: Lens.Lens' StackSummary (Prelude.Maybe StackDriftInformationSummary)
stackSummary_driftInformation :: Lens' StackSummary (Maybe StackDriftInformationSummary)
stackSummary_driftInformation = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\StackSummary' {Maybe StackDriftInformationSummary
driftInformation :: Maybe StackDriftInformationSummary
$sel:driftInformation:StackSummary' :: StackSummary -> Maybe StackDriftInformationSummary
driftInformation} -> Maybe StackDriftInformationSummary
driftInformation) (\s :: StackSummary
s@StackSummary' {} Maybe StackDriftInformationSummary
a -> StackSummary
s {$sel:driftInformation:StackSummary' :: Maybe StackDriftInformationSummary
driftInformation = Maybe StackDriftInformationSummary
a} :: StackSummary)
stackSummary_lastUpdatedTime :: Lens.Lens' StackSummary (Prelude.Maybe Prelude.UTCTime)
stackSummary_lastUpdatedTime :: Lens' StackSummary (Maybe UTCTime)
stackSummary_lastUpdatedTime = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\StackSummary' {Maybe ISO8601
lastUpdatedTime :: Maybe ISO8601
$sel:lastUpdatedTime:StackSummary' :: StackSummary -> Maybe ISO8601
lastUpdatedTime} -> Maybe ISO8601
lastUpdatedTime) (\s :: StackSummary
s@StackSummary' {} Maybe ISO8601
a -> StackSummary
s {$sel:lastUpdatedTime:StackSummary' :: Maybe ISO8601
lastUpdatedTime = Maybe ISO8601
a} :: StackSummary) forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. 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 forall (a :: Format). Iso' (Time a) UTCTime
Data._Time
stackSummary_parentId :: Lens.Lens' StackSummary (Prelude.Maybe Prelude.Text)
stackSummary_parentId :: Lens' StackSummary (Maybe Text)
stackSummary_parentId = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\StackSummary' {Maybe Text
parentId :: Maybe Text
$sel:parentId:StackSummary' :: StackSummary -> Maybe Text
parentId} -> Maybe Text
parentId) (\s :: StackSummary
s@StackSummary' {} Maybe Text
a -> StackSummary
s {$sel:parentId:StackSummary' :: Maybe Text
parentId = Maybe Text
a} :: StackSummary)
stackSummary_rootId :: Lens.Lens' StackSummary (Prelude.Maybe Prelude.Text)
stackSummary_rootId :: Lens' StackSummary (Maybe Text)
stackSummary_rootId = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\StackSummary' {Maybe Text
rootId :: Maybe Text
$sel:rootId:StackSummary' :: StackSummary -> Maybe Text
rootId} -> Maybe Text
rootId) (\s :: StackSummary
s@StackSummary' {} Maybe Text
a -> StackSummary
s {$sel:rootId:StackSummary' :: Maybe Text
rootId = Maybe Text
a} :: StackSummary)
stackSummary_stackId :: Lens.Lens' StackSummary (Prelude.Maybe Prelude.Text)
stackSummary_stackId :: Lens' StackSummary (Maybe Text)
stackSummary_stackId = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\StackSummary' {Maybe Text
stackId :: Maybe Text
$sel:stackId:StackSummary' :: StackSummary -> Maybe Text
stackId} -> Maybe Text
stackId) (\s :: StackSummary
s@StackSummary' {} Maybe Text
a -> StackSummary
s {$sel:stackId:StackSummary' :: Maybe Text
stackId = Maybe Text
a} :: StackSummary)
stackSummary_stackStatusReason :: Lens.Lens' StackSummary (Prelude.Maybe Prelude.Text)
stackSummary_stackStatusReason :: Lens' StackSummary (Maybe Text)
stackSummary_stackStatusReason = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\StackSummary' {Maybe Text
stackStatusReason :: Maybe Text
$sel:stackStatusReason:StackSummary' :: StackSummary -> Maybe Text
stackStatusReason} -> Maybe Text
stackStatusReason) (\s :: StackSummary
s@StackSummary' {} Maybe Text
a -> StackSummary
s {$sel:stackStatusReason:StackSummary' :: Maybe Text
stackStatusReason = Maybe Text
a} :: StackSummary)
stackSummary_templateDescription :: Lens.Lens' StackSummary (Prelude.Maybe Prelude.Text)
stackSummary_templateDescription :: Lens' StackSummary (Maybe Text)
stackSummary_templateDescription = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\StackSummary' {Maybe Text
templateDescription :: Maybe Text
$sel:templateDescription:StackSummary' :: StackSummary -> Maybe Text
templateDescription} -> Maybe Text
templateDescription) (\s :: StackSummary
s@StackSummary' {} Maybe Text
a -> StackSummary
s {$sel:templateDescription:StackSummary' :: Maybe Text
templateDescription = Maybe Text
a} :: StackSummary)
stackSummary_stackName :: Lens.Lens' StackSummary Prelude.Text
stackSummary_stackName :: Lens' StackSummary Text
stackSummary_stackName = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\StackSummary' {Text
stackName :: Text
$sel:stackName:StackSummary' :: StackSummary -> Text
stackName} -> Text
stackName) (\s :: StackSummary
s@StackSummary' {} Text
a -> StackSummary
s {$sel:stackName:StackSummary' :: Text
stackName = Text
a} :: StackSummary)
stackSummary_creationTime :: Lens.Lens' StackSummary Prelude.UTCTime
stackSummary_creationTime :: Lens' StackSummary UTCTime
stackSummary_creationTime = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\StackSummary' {ISO8601
creationTime :: ISO8601
$sel:creationTime:StackSummary' :: StackSummary -> ISO8601
creationTime} -> ISO8601
creationTime) (\s :: StackSummary
s@StackSummary' {} ISO8601
a -> StackSummary
s {$sel:creationTime:StackSummary' :: ISO8601
creationTime = ISO8601
a} :: StackSummary) forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. forall (a :: Format). Iso' (Time a) UTCTime
Data._Time
stackSummary_stackStatus :: Lens.Lens' StackSummary StackStatus
stackSummary_stackStatus :: Lens' StackSummary StackStatus
stackSummary_stackStatus = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\StackSummary' {StackStatus
stackStatus :: StackStatus
$sel:stackStatus:StackSummary' :: StackSummary -> StackStatus
stackStatus} -> StackStatus
stackStatus) (\s :: StackSummary
s@StackSummary' {} StackStatus
a -> StackSummary
s {$sel:stackStatus:StackSummary' :: StackStatus
stackStatus = StackStatus
a} :: StackSummary)
instance Data.FromXML StackSummary where
parseXML :: [Node] -> Either String StackSummary
parseXML [Node]
x =
Maybe ISO8601
-> Maybe StackDriftInformationSummary
-> Maybe ISO8601
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Text
-> ISO8601
-> StackStatus
-> StackSummary
StackSummary'
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> ([Node]
x forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Data..@? Text
"DeletionTime")
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ([Node]
x forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Data..@? Text
"DriftInformation")
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ([Node]
x forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Data..@? Text
"LastUpdatedTime")
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ([Node]
x forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Data..@? Text
"ParentId")
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ([Node]
x forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Data..@? Text
"RootId")
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ([Node]
x forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Data..@? Text
"StackId")
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ([Node]
x forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Data..@? Text
"StackStatusReason")
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ([Node]
x forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Data..@? Text
"TemplateDescription")
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ([Node]
x forall a. FromXML a => [Node] -> Text -> Either String a
Data..@ Text
"StackName")
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ([Node]
x forall a. FromXML a => [Node] -> Text -> Either String a
Data..@ Text
"CreationTime")
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ([Node]
x forall a. FromXML a => [Node] -> Text -> Either String a
Data..@ Text
"StackStatus")
instance Prelude.Hashable StackSummary where
hashWithSalt :: Int -> StackSummary -> Int
hashWithSalt Int
_salt StackSummary' {Maybe Text
Maybe ISO8601
Maybe StackDriftInformationSummary
Text
ISO8601
StackStatus
stackStatus :: StackStatus
creationTime :: ISO8601
stackName :: Text
templateDescription :: Maybe Text
stackStatusReason :: Maybe Text
stackId :: Maybe Text
rootId :: Maybe Text
parentId :: Maybe Text
lastUpdatedTime :: Maybe ISO8601
driftInformation :: Maybe StackDriftInformationSummary
deletionTime :: Maybe ISO8601
$sel:stackStatus:StackSummary' :: StackSummary -> StackStatus
$sel:creationTime:StackSummary' :: StackSummary -> ISO8601
$sel:stackName:StackSummary' :: StackSummary -> Text
$sel:templateDescription:StackSummary' :: StackSummary -> Maybe Text
$sel:stackStatusReason:StackSummary' :: StackSummary -> Maybe Text
$sel:stackId:StackSummary' :: StackSummary -> Maybe Text
$sel:rootId:StackSummary' :: StackSummary -> Maybe Text
$sel:parentId:StackSummary' :: StackSummary -> Maybe Text
$sel:lastUpdatedTime:StackSummary' :: StackSummary -> Maybe ISO8601
$sel:driftInformation:StackSummary' :: StackSummary -> Maybe StackDriftInformationSummary
$sel:deletionTime:StackSummary' :: StackSummary -> Maybe ISO8601
..} =
Int
_salt
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe ISO8601
deletionTime
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe StackDriftInformationSummary
driftInformation
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe ISO8601
lastUpdatedTime
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
parentId
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
rootId
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
stackId
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
stackStatusReason
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
templateDescription
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Text
stackName
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` ISO8601
creationTime
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` StackStatus
stackStatus
instance Prelude.NFData StackSummary where
rnf :: StackSummary -> ()
rnf StackSummary' {Maybe Text
Maybe ISO8601
Maybe StackDriftInformationSummary
Text
ISO8601
StackStatus
stackStatus :: StackStatus
creationTime :: ISO8601
stackName :: Text
templateDescription :: Maybe Text
stackStatusReason :: Maybe Text
stackId :: Maybe Text
rootId :: Maybe Text
parentId :: Maybe Text
lastUpdatedTime :: Maybe ISO8601
driftInformation :: Maybe StackDriftInformationSummary
deletionTime :: Maybe ISO8601
$sel:stackStatus:StackSummary' :: StackSummary -> StackStatus
$sel:creationTime:StackSummary' :: StackSummary -> ISO8601
$sel:stackName:StackSummary' :: StackSummary -> Text
$sel:templateDescription:StackSummary' :: StackSummary -> Maybe Text
$sel:stackStatusReason:StackSummary' :: StackSummary -> Maybe Text
$sel:stackId:StackSummary' :: StackSummary -> Maybe Text
$sel:rootId:StackSummary' :: StackSummary -> Maybe Text
$sel:parentId:StackSummary' :: StackSummary -> Maybe Text
$sel:lastUpdatedTime:StackSummary' :: StackSummary -> Maybe ISO8601
$sel:driftInformation:StackSummary' :: StackSummary -> Maybe StackDriftInformationSummary
$sel:deletionTime:StackSummary' :: StackSummary -> Maybe ISO8601
..} =
forall a. NFData a => a -> ()
Prelude.rnf Maybe ISO8601
deletionTime
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe StackDriftInformationSummary
driftInformation
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe ISO8601
lastUpdatedTime
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
parentId
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
rootId
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
stackId
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
stackStatusReason
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
templateDescription
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Text
stackName
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf ISO8601
creationTime
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf StackStatus
stackStatus