{-# 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.CodeDeploy.Types.DeploymentOverview where
import qualified Amazonka.Core as Core
import qualified Amazonka.Lens as Lens
import qualified Amazonka.Prelude as Prelude
data DeploymentOverview = DeploymentOverview'
{
DeploymentOverview -> Maybe Integer
pending :: Prelude.Maybe Prelude.Integer,
DeploymentOverview -> Maybe Integer
skipped :: Prelude.Maybe Prelude.Integer,
DeploymentOverview -> Maybe Integer
inProgress :: Prelude.Maybe Prelude.Integer,
DeploymentOverview -> Maybe Integer
succeeded :: Prelude.Maybe Prelude.Integer,
DeploymentOverview -> Maybe Integer
ready :: Prelude.Maybe Prelude.Integer,
DeploymentOverview -> Maybe Integer
failed :: Prelude.Maybe Prelude.Integer
}
deriving (DeploymentOverview -> DeploymentOverview -> Bool
(DeploymentOverview -> DeploymentOverview -> Bool)
-> (DeploymentOverview -> DeploymentOverview -> Bool)
-> Eq DeploymentOverview
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: DeploymentOverview -> DeploymentOverview -> Bool
$c/= :: DeploymentOverview -> DeploymentOverview -> Bool
== :: DeploymentOverview -> DeploymentOverview -> Bool
$c== :: DeploymentOverview -> DeploymentOverview -> Bool
Prelude.Eq, ReadPrec [DeploymentOverview]
ReadPrec DeploymentOverview
Int -> ReadS DeploymentOverview
ReadS [DeploymentOverview]
(Int -> ReadS DeploymentOverview)
-> ReadS [DeploymentOverview]
-> ReadPrec DeploymentOverview
-> ReadPrec [DeploymentOverview]
-> Read DeploymentOverview
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [DeploymentOverview]
$creadListPrec :: ReadPrec [DeploymentOverview]
readPrec :: ReadPrec DeploymentOverview
$creadPrec :: ReadPrec DeploymentOverview
readList :: ReadS [DeploymentOverview]
$creadList :: ReadS [DeploymentOverview]
readsPrec :: Int -> ReadS DeploymentOverview
$creadsPrec :: Int -> ReadS DeploymentOverview
Prelude.Read, Int -> DeploymentOverview -> ShowS
[DeploymentOverview] -> ShowS
DeploymentOverview -> String
(Int -> DeploymentOverview -> ShowS)
-> (DeploymentOverview -> String)
-> ([DeploymentOverview] -> ShowS)
-> Show DeploymentOverview
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [DeploymentOverview] -> ShowS
$cshowList :: [DeploymentOverview] -> ShowS
show :: DeploymentOverview -> String
$cshow :: DeploymentOverview -> String
showsPrec :: Int -> DeploymentOverview -> ShowS
$cshowsPrec :: Int -> DeploymentOverview -> ShowS
Prelude.Show, (forall x. DeploymentOverview -> Rep DeploymentOverview x)
-> (forall x. Rep DeploymentOverview x -> DeploymentOverview)
-> Generic DeploymentOverview
forall x. Rep DeploymentOverview x -> DeploymentOverview
forall x. DeploymentOverview -> Rep DeploymentOverview x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep DeploymentOverview x -> DeploymentOverview
$cfrom :: forall x. DeploymentOverview -> Rep DeploymentOverview x
Prelude.Generic)
newDeploymentOverview ::
DeploymentOverview
newDeploymentOverview :: DeploymentOverview
newDeploymentOverview =
DeploymentOverview' :: Maybe Integer
-> Maybe Integer
-> Maybe Integer
-> Maybe Integer
-> Maybe Integer
-> Maybe Integer
-> DeploymentOverview
DeploymentOverview'
{ $sel:pending:DeploymentOverview' :: Maybe Integer
pending = Maybe Integer
forall a. Maybe a
Prelude.Nothing,
$sel:skipped:DeploymentOverview' :: Maybe Integer
skipped = Maybe Integer
forall a. Maybe a
Prelude.Nothing,
$sel:inProgress:DeploymentOverview' :: Maybe Integer
inProgress = Maybe Integer
forall a. Maybe a
Prelude.Nothing,
$sel:succeeded:DeploymentOverview' :: Maybe Integer
succeeded = Maybe Integer
forall a. Maybe a
Prelude.Nothing,
$sel:ready:DeploymentOverview' :: Maybe Integer
ready = Maybe Integer
forall a. Maybe a
Prelude.Nothing,
$sel:failed:DeploymentOverview' :: Maybe Integer
failed = Maybe Integer
forall a. Maybe a
Prelude.Nothing
}
deploymentOverview_pending :: Lens.Lens' DeploymentOverview (Prelude.Maybe Prelude.Integer)
deploymentOverview_pending :: (Maybe Integer -> f (Maybe Integer))
-> DeploymentOverview -> f DeploymentOverview
deploymentOverview_pending = (DeploymentOverview -> Maybe Integer)
-> (DeploymentOverview -> Maybe Integer -> DeploymentOverview)
-> Lens
DeploymentOverview
DeploymentOverview
(Maybe Integer)
(Maybe Integer)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DeploymentOverview' {Maybe Integer
pending :: Maybe Integer
$sel:pending:DeploymentOverview' :: DeploymentOverview -> Maybe Integer
pending} -> Maybe Integer
pending) (\s :: DeploymentOverview
s@DeploymentOverview' {} Maybe Integer
a -> DeploymentOverview
s {$sel:pending:DeploymentOverview' :: Maybe Integer
pending = Maybe Integer
a} :: DeploymentOverview)
deploymentOverview_skipped :: Lens.Lens' DeploymentOverview (Prelude.Maybe Prelude.Integer)
deploymentOverview_skipped :: (Maybe Integer -> f (Maybe Integer))
-> DeploymentOverview -> f DeploymentOverview
deploymentOverview_skipped = (DeploymentOverview -> Maybe Integer)
-> (DeploymentOverview -> Maybe Integer -> DeploymentOverview)
-> Lens
DeploymentOverview
DeploymentOverview
(Maybe Integer)
(Maybe Integer)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DeploymentOverview' {Maybe Integer
skipped :: Maybe Integer
$sel:skipped:DeploymentOverview' :: DeploymentOverview -> Maybe Integer
skipped} -> Maybe Integer
skipped) (\s :: DeploymentOverview
s@DeploymentOverview' {} Maybe Integer
a -> DeploymentOverview
s {$sel:skipped:DeploymentOverview' :: Maybe Integer
skipped = Maybe Integer
a} :: DeploymentOverview)
deploymentOverview_inProgress :: Lens.Lens' DeploymentOverview (Prelude.Maybe Prelude.Integer)
deploymentOverview_inProgress :: (Maybe Integer -> f (Maybe Integer))
-> DeploymentOverview -> f DeploymentOverview
deploymentOverview_inProgress = (DeploymentOverview -> Maybe Integer)
-> (DeploymentOverview -> Maybe Integer -> DeploymentOverview)
-> Lens
DeploymentOverview
DeploymentOverview
(Maybe Integer)
(Maybe Integer)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DeploymentOverview' {Maybe Integer
inProgress :: Maybe Integer
$sel:inProgress:DeploymentOverview' :: DeploymentOverview -> Maybe Integer
inProgress} -> Maybe Integer
inProgress) (\s :: DeploymentOverview
s@DeploymentOverview' {} Maybe Integer
a -> DeploymentOverview
s {$sel:inProgress:DeploymentOverview' :: Maybe Integer
inProgress = Maybe Integer
a} :: DeploymentOverview)
deploymentOverview_succeeded :: Lens.Lens' DeploymentOverview (Prelude.Maybe Prelude.Integer)
deploymentOverview_succeeded :: (Maybe Integer -> f (Maybe Integer))
-> DeploymentOverview -> f DeploymentOverview
deploymentOverview_succeeded = (DeploymentOverview -> Maybe Integer)
-> (DeploymentOverview -> Maybe Integer -> DeploymentOverview)
-> Lens
DeploymentOverview
DeploymentOverview
(Maybe Integer)
(Maybe Integer)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DeploymentOverview' {Maybe Integer
succeeded :: Maybe Integer
$sel:succeeded:DeploymentOverview' :: DeploymentOverview -> Maybe Integer
succeeded} -> Maybe Integer
succeeded) (\s :: DeploymentOverview
s@DeploymentOverview' {} Maybe Integer
a -> DeploymentOverview
s {$sel:succeeded:DeploymentOverview' :: Maybe Integer
succeeded = Maybe Integer
a} :: DeploymentOverview)
deploymentOverview_ready :: Lens.Lens' DeploymentOverview (Prelude.Maybe Prelude.Integer)
deploymentOverview_ready :: (Maybe Integer -> f (Maybe Integer))
-> DeploymentOverview -> f DeploymentOverview
deploymentOverview_ready = (DeploymentOverview -> Maybe Integer)
-> (DeploymentOverview -> Maybe Integer -> DeploymentOverview)
-> Lens
DeploymentOverview
DeploymentOverview
(Maybe Integer)
(Maybe Integer)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DeploymentOverview' {Maybe Integer
ready :: Maybe Integer
$sel:ready:DeploymentOverview' :: DeploymentOverview -> Maybe Integer
ready} -> Maybe Integer
ready) (\s :: DeploymentOverview
s@DeploymentOverview' {} Maybe Integer
a -> DeploymentOverview
s {$sel:ready:DeploymentOverview' :: Maybe Integer
ready = Maybe Integer
a} :: DeploymentOverview)
deploymentOverview_failed :: Lens.Lens' DeploymentOverview (Prelude.Maybe Prelude.Integer)
deploymentOverview_failed :: (Maybe Integer -> f (Maybe Integer))
-> DeploymentOverview -> f DeploymentOverview
deploymentOverview_failed = (DeploymentOverview -> Maybe Integer)
-> (DeploymentOverview -> Maybe Integer -> DeploymentOverview)
-> Lens
DeploymentOverview
DeploymentOverview
(Maybe Integer)
(Maybe Integer)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DeploymentOverview' {Maybe Integer
failed :: Maybe Integer
$sel:failed:DeploymentOverview' :: DeploymentOverview -> Maybe Integer
failed} -> Maybe Integer
failed) (\s :: DeploymentOverview
s@DeploymentOverview' {} Maybe Integer
a -> DeploymentOverview
s {$sel:failed:DeploymentOverview' :: Maybe Integer
failed = Maybe Integer
a} :: DeploymentOverview)
instance Core.FromJSON DeploymentOverview where
parseJSON :: Value -> Parser DeploymentOverview
parseJSON =
String
-> (Object -> Parser DeploymentOverview)
-> Value
-> Parser DeploymentOverview
forall a. String -> (Object -> Parser a) -> Value -> Parser a
Core.withObject
String
"DeploymentOverview"
( \Object
x ->
Maybe Integer
-> Maybe Integer
-> Maybe Integer
-> Maybe Integer
-> Maybe Integer
-> Maybe Integer
-> DeploymentOverview
DeploymentOverview'
(Maybe Integer
-> Maybe Integer
-> Maybe Integer
-> Maybe Integer
-> Maybe Integer
-> Maybe Integer
-> DeploymentOverview)
-> Parser (Maybe Integer)
-> Parser
(Maybe Integer
-> Maybe Integer
-> Maybe Integer
-> Maybe Integer
-> Maybe Integer
-> DeploymentOverview)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Object
x Object -> Text -> Parser (Maybe Integer)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"Pending")
Parser
(Maybe Integer
-> Maybe Integer
-> Maybe Integer
-> Maybe Integer
-> Maybe Integer
-> DeploymentOverview)
-> Parser (Maybe Integer)
-> Parser
(Maybe Integer
-> Maybe Integer
-> Maybe Integer
-> Maybe Integer
-> DeploymentOverview)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Integer)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"Skipped")
Parser
(Maybe Integer
-> Maybe Integer
-> Maybe Integer
-> Maybe Integer
-> DeploymentOverview)
-> Parser (Maybe Integer)
-> Parser
(Maybe Integer
-> Maybe Integer -> Maybe Integer -> DeploymentOverview)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Integer)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"InProgress")
Parser
(Maybe Integer
-> Maybe Integer -> Maybe Integer -> DeploymentOverview)
-> Parser (Maybe Integer)
-> Parser (Maybe Integer -> Maybe Integer -> DeploymentOverview)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Integer)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"Succeeded")
Parser (Maybe Integer -> Maybe Integer -> DeploymentOverview)
-> Parser (Maybe Integer)
-> Parser (Maybe Integer -> DeploymentOverview)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Integer)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"Ready")
Parser (Maybe Integer -> DeploymentOverview)
-> Parser (Maybe Integer) -> Parser DeploymentOverview
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Integer)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"Failed")
)
instance Prelude.Hashable DeploymentOverview
instance Prelude.NFData DeploymentOverview