{-# 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.ApplicationInsights.Types.ApplicationInfo where
import qualified Amazonka.Core as Core
import qualified Amazonka.Lens as Lens
import qualified Amazonka.Prelude as Prelude
data ApplicationInfo = ApplicationInfo'
{
ApplicationInfo -> Maybe Text
resourceGroupName :: Prelude.Maybe Prelude.Text,
ApplicationInfo -> Maybe Bool
cWEMonitorEnabled :: Prelude.Maybe Prelude.Bool,
ApplicationInfo -> Maybe Text
opsItemSNSTopicArn :: Prelude.Maybe Prelude.Text,
ApplicationInfo -> Maybe Text
lifeCycle :: Prelude.Maybe Prelude.Text,
ApplicationInfo -> Maybe Bool
opsCenterEnabled :: Prelude.Maybe Prelude.Bool,
:: Prelude.Maybe Prelude.Text
}
deriving (ApplicationInfo -> ApplicationInfo -> Bool
(ApplicationInfo -> ApplicationInfo -> Bool)
-> (ApplicationInfo -> ApplicationInfo -> Bool)
-> Eq ApplicationInfo
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: ApplicationInfo -> ApplicationInfo -> Bool
$c/= :: ApplicationInfo -> ApplicationInfo -> Bool
== :: ApplicationInfo -> ApplicationInfo -> Bool
$c== :: ApplicationInfo -> ApplicationInfo -> Bool
Prelude.Eq, ReadPrec [ApplicationInfo]
ReadPrec ApplicationInfo
Int -> ReadS ApplicationInfo
ReadS [ApplicationInfo]
(Int -> ReadS ApplicationInfo)
-> ReadS [ApplicationInfo]
-> ReadPrec ApplicationInfo
-> ReadPrec [ApplicationInfo]
-> Read ApplicationInfo
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [ApplicationInfo]
$creadListPrec :: ReadPrec [ApplicationInfo]
readPrec :: ReadPrec ApplicationInfo
$creadPrec :: ReadPrec ApplicationInfo
readList :: ReadS [ApplicationInfo]
$creadList :: ReadS [ApplicationInfo]
readsPrec :: Int -> ReadS ApplicationInfo
$creadsPrec :: Int -> ReadS ApplicationInfo
Prelude.Read, Int -> ApplicationInfo -> ShowS
[ApplicationInfo] -> ShowS
ApplicationInfo -> String
(Int -> ApplicationInfo -> ShowS)
-> (ApplicationInfo -> String)
-> ([ApplicationInfo] -> ShowS)
-> Show ApplicationInfo
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [ApplicationInfo] -> ShowS
$cshowList :: [ApplicationInfo] -> ShowS
show :: ApplicationInfo -> String
$cshow :: ApplicationInfo -> String
showsPrec :: Int -> ApplicationInfo -> ShowS
$cshowsPrec :: Int -> ApplicationInfo -> ShowS
Prelude.Show, (forall x. ApplicationInfo -> Rep ApplicationInfo x)
-> (forall x. Rep ApplicationInfo x -> ApplicationInfo)
-> Generic ApplicationInfo
forall x. Rep ApplicationInfo x -> ApplicationInfo
forall x. ApplicationInfo -> Rep ApplicationInfo x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep ApplicationInfo x -> ApplicationInfo
$cfrom :: forall x. ApplicationInfo -> Rep ApplicationInfo x
Prelude.Generic)
newApplicationInfo ::
ApplicationInfo
newApplicationInfo :: ApplicationInfo
newApplicationInfo =
ApplicationInfo' :: Maybe Text
-> Maybe Bool
-> Maybe Text
-> Maybe Text
-> Maybe Bool
-> Maybe Text
-> ApplicationInfo
ApplicationInfo'
{ $sel:resourceGroupName:ApplicationInfo' :: Maybe Text
resourceGroupName =
Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:cWEMonitorEnabled:ApplicationInfo' :: Maybe Bool
cWEMonitorEnabled = Maybe Bool
forall a. Maybe a
Prelude.Nothing,
$sel:opsItemSNSTopicArn:ApplicationInfo' :: Maybe Text
opsItemSNSTopicArn = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:lifeCycle:ApplicationInfo' :: Maybe Text
lifeCycle = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:opsCenterEnabled:ApplicationInfo' :: Maybe Bool
opsCenterEnabled = Maybe Bool
forall a. Maybe a
Prelude.Nothing,
$sel:remarks:ApplicationInfo' :: Maybe Text
remarks = Maybe Text
forall a. Maybe a
Prelude.Nothing
}
applicationInfo_resourceGroupName :: Lens.Lens' ApplicationInfo (Prelude.Maybe Prelude.Text)
applicationInfo_resourceGroupName :: (Maybe Text -> f (Maybe Text))
-> ApplicationInfo -> f ApplicationInfo
applicationInfo_resourceGroupName = (ApplicationInfo -> Maybe Text)
-> (ApplicationInfo -> Maybe Text -> ApplicationInfo)
-> Lens ApplicationInfo ApplicationInfo (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ApplicationInfo' {Maybe Text
resourceGroupName :: Maybe Text
$sel:resourceGroupName:ApplicationInfo' :: ApplicationInfo -> Maybe Text
resourceGroupName} -> Maybe Text
resourceGroupName) (\s :: ApplicationInfo
s@ApplicationInfo' {} Maybe Text
a -> ApplicationInfo
s {$sel:resourceGroupName:ApplicationInfo' :: Maybe Text
resourceGroupName = Maybe Text
a} :: ApplicationInfo)
applicationInfo_cWEMonitorEnabled :: Lens.Lens' ApplicationInfo (Prelude.Maybe Prelude.Bool)
applicationInfo_cWEMonitorEnabled :: (Maybe Bool -> f (Maybe Bool))
-> ApplicationInfo -> f ApplicationInfo
applicationInfo_cWEMonitorEnabled = (ApplicationInfo -> Maybe Bool)
-> (ApplicationInfo -> Maybe Bool -> ApplicationInfo)
-> Lens ApplicationInfo ApplicationInfo (Maybe Bool) (Maybe Bool)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ApplicationInfo' {Maybe Bool
cWEMonitorEnabled :: Maybe Bool
$sel:cWEMonitorEnabled:ApplicationInfo' :: ApplicationInfo -> Maybe Bool
cWEMonitorEnabled} -> Maybe Bool
cWEMonitorEnabled) (\s :: ApplicationInfo
s@ApplicationInfo' {} Maybe Bool
a -> ApplicationInfo
s {$sel:cWEMonitorEnabled:ApplicationInfo' :: Maybe Bool
cWEMonitorEnabled = Maybe Bool
a} :: ApplicationInfo)
applicationInfo_opsItemSNSTopicArn :: Lens.Lens' ApplicationInfo (Prelude.Maybe Prelude.Text)
applicationInfo_opsItemSNSTopicArn :: (Maybe Text -> f (Maybe Text))
-> ApplicationInfo -> f ApplicationInfo
applicationInfo_opsItemSNSTopicArn = (ApplicationInfo -> Maybe Text)
-> (ApplicationInfo -> Maybe Text -> ApplicationInfo)
-> Lens ApplicationInfo ApplicationInfo (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ApplicationInfo' {Maybe Text
opsItemSNSTopicArn :: Maybe Text
$sel:opsItemSNSTopicArn:ApplicationInfo' :: ApplicationInfo -> Maybe Text
opsItemSNSTopicArn} -> Maybe Text
opsItemSNSTopicArn) (\s :: ApplicationInfo
s@ApplicationInfo' {} Maybe Text
a -> ApplicationInfo
s {$sel:opsItemSNSTopicArn:ApplicationInfo' :: Maybe Text
opsItemSNSTopicArn = Maybe Text
a} :: ApplicationInfo)
applicationInfo_lifeCycle :: Lens.Lens' ApplicationInfo (Prelude.Maybe Prelude.Text)
applicationInfo_lifeCycle :: (Maybe Text -> f (Maybe Text))
-> ApplicationInfo -> f ApplicationInfo
applicationInfo_lifeCycle = (ApplicationInfo -> Maybe Text)
-> (ApplicationInfo -> Maybe Text -> ApplicationInfo)
-> Lens ApplicationInfo ApplicationInfo (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ApplicationInfo' {Maybe Text
lifeCycle :: Maybe Text
$sel:lifeCycle:ApplicationInfo' :: ApplicationInfo -> Maybe Text
lifeCycle} -> Maybe Text
lifeCycle) (\s :: ApplicationInfo
s@ApplicationInfo' {} Maybe Text
a -> ApplicationInfo
s {$sel:lifeCycle:ApplicationInfo' :: Maybe Text
lifeCycle = Maybe Text
a} :: ApplicationInfo)
applicationInfo_opsCenterEnabled :: Lens.Lens' ApplicationInfo (Prelude.Maybe Prelude.Bool)
applicationInfo_opsCenterEnabled :: (Maybe Bool -> f (Maybe Bool))
-> ApplicationInfo -> f ApplicationInfo
applicationInfo_opsCenterEnabled = (ApplicationInfo -> Maybe Bool)
-> (ApplicationInfo -> Maybe Bool -> ApplicationInfo)
-> Lens ApplicationInfo ApplicationInfo (Maybe Bool) (Maybe Bool)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ApplicationInfo' {Maybe Bool
opsCenterEnabled :: Maybe Bool
$sel:opsCenterEnabled:ApplicationInfo' :: ApplicationInfo -> Maybe Bool
opsCenterEnabled} -> Maybe Bool
opsCenterEnabled) (\s :: ApplicationInfo
s@ApplicationInfo' {} Maybe Bool
a -> ApplicationInfo
s {$sel:opsCenterEnabled:ApplicationInfo' :: Maybe Bool
opsCenterEnabled = Maybe Bool
a} :: ApplicationInfo)
applicationInfo_remarks :: Lens.Lens' ApplicationInfo (Prelude.Maybe Prelude.Text)
= (ApplicationInfo -> Maybe Text)
-> (ApplicationInfo -> Maybe Text -> ApplicationInfo)
-> Lens ApplicationInfo ApplicationInfo (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ApplicationInfo' {Maybe Text
remarks :: Maybe Text
$sel:remarks:ApplicationInfo' :: ApplicationInfo -> Maybe Text
remarks} -> Maybe Text
remarks) (\s :: ApplicationInfo
s@ApplicationInfo' {} Maybe Text
a -> ApplicationInfo
s {$sel:remarks:ApplicationInfo' :: Maybe Text
remarks = Maybe Text
a} :: ApplicationInfo)
instance Core.FromJSON ApplicationInfo where
parseJSON :: Value -> Parser ApplicationInfo
parseJSON =
String
-> (Object -> Parser ApplicationInfo)
-> Value
-> Parser ApplicationInfo
forall a. String -> (Object -> Parser a) -> Value -> Parser a
Core.withObject
String
"ApplicationInfo"
( \Object
x ->
Maybe Text
-> Maybe Bool
-> Maybe Text
-> Maybe Text
-> Maybe Bool
-> Maybe Text
-> ApplicationInfo
ApplicationInfo'
(Maybe Text
-> Maybe Bool
-> Maybe Text
-> Maybe Text
-> Maybe Bool
-> Maybe Text
-> ApplicationInfo)
-> Parser (Maybe Text)
-> Parser
(Maybe Bool
-> Maybe Text
-> Maybe Text
-> Maybe Bool
-> Maybe Text
-> ApplicationInfo)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Object
x Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"ResourceGroupName")
Parser
(Maybe Bool
-> Maybe Text
-> Maybe Text
-> Maybe Bool
-> Maybe Text
-> ApplicationInfo)
-> Parser (Maybe Bool)
-> Parser
(Maybe Text
-> Maybe Text -> Maybe Bool -> Maybe Text -> ApplicationInfo)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Bool)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"CWEMonitorEnabled")
Parser
(Maybe Text
-> Maybe Text -> Maybe Bool -> Maybe Text -> ApplicationInfo)
-> Parser (Maybe Text)
-> Parser
(Maybe Text -> Maybe Bool -> Maybe Text -> ApplicationInfo)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"OpsItemSNSTopicArn")
Parser (Maybe Text -> Maybe Bool -> Maybe Text -> ApplicationInfo)
-> Parser (Maybe Text)
-> Parser (Maybe Bool -> Maybe Text -> ApplicationInfo)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"LifeCycle")
Parser (Maybe Bool -> Maybe Text -> ApplicationInfo)
-> Parser (Maybe Bool) -> Parser (Maybe Text -> ApplicationInfo)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Bool)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"OpsCenterEnabled")
Parser (Maybe Text -> ApplicationInfo)
-> Parser (Maybe Text) -> Parser ApplicationInfo
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"Remarks")
)
instance Prelude.Hashable ApplicationInfo
instance Prelude.NFData ApplicationInfo