{-# 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.Route53RecoveryReadiness.Types.ListRulesOutput where
import qualified Amazonka.Core as Core
import qualified Amazonka.Lens as Lens
import qualified Amazonka.Prelude as Prelude
data ListRulesOutput = ListRulesOutput'
{
ListRulesOutput -> Text
ruleDescription :: Prelude.Text,
ListRulesOutput -> Text
ruleId :: Prelude.Text,
ListRulesOutput -> Text
resourceType :: Prelude.Text
}
deriving (ListRulesOutput -> ListRulesOutput -> Bool
(ListRulesOutput -> ListRulesOutput -> Bool)
-> (ListRulesOutput -> ListRulesOutput -> Bool)
-> Eq ListRulesOutput
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: ListRulesOutput -> ListRulesOutput -> Bool
$c/= :: ListRulesOutput -> ListRulesOutput -> Bool
== :: ListRulesOutput -> ListRulesOutput -> Bool
$c== :: ListRulesOutput -> ListRulesOutput -> Bool
Prelude.Eq, ReadPrec [ListRulesOutput]
ReadPrec ListRulesOutput
Int -> ReadS ListRulesOutput
ReadS [ListRulesOutput]
(Int -> ReadS ListRulesOutput)
-> ReadS [ListRulesOutput]
-> ReadPrec ListRulesOutput
-> ReadPrec [ListRulesOutput]
-> Read ListRulesOutput
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [ListRulesOutput]
$creadListPrec :: ReadPrec [ListRulesOutput]
readPrec :: ReadPrec ListRulesOutput
$creadPrec :: ReadPrec ListRulesOutput
readList :: ReadS [ListRulesOutput]
$creadList :: ReadS [ListRulesOutput]
readsPrec :: Int -> ReadS ListRulesOutput
$creadsPrec :: Int -> ReadS ListRulesOutput
Prelude.Read, Int -> ListRulesOutput -> ShowS
[ListRulesOutput] -> ShowS
ListRulesOutput -> String
(Int -> ListRulesOutput -> ShowS)
-> (ListRulesOutput -> String)
-> ([ListRulesOutput] -> ShowS)
-> Show ListRulesOutput
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [ListRulesOutput] -> ShowS
$cshowList :: [ListRulesOutput] -> ShowS
show :: ListRulesOutput -> String
$cshow :: ListRulesOutput -> String
showsPrec :: Int -> ListRulesOutput -> ShowS
$cshowsPrec :: Int -> ListRulesOutput -> ShowS
Prelude.Show, (forall x. ListRulesOutput -> Rep ListRulesOutput x)
-> (forall x. Rep ListRulesOutput x -> ListRulesOutput)
-> Generic ListRulesOutput
forall x. Rep ListRulesOutput x -> ListRulesOutput
forall x. ListRulesOutput -> Rep ListRulesOutput x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep ListRulesOutput x -> ListRulesOutput
$cfrom :: forall x. ListRulesOutput -> Rep ListRulesOutput x
Prelude.Generic)
newListRulesOutput ::
Prelude.Text ->
Prelude.Text ->
Prelude.Text ->
ListRulesOutput
newListRulesOutput :: Text -> Text -> Text -> ListRulesOutput
newListRulesOutput
Text
pRuleDescription_
Text
pRuleId_
Text
pResourceType_ =
ListRulesOutput' :: Text -> Text -> Text -> ListRulesOutput
ListRulesOutput'
{ $sel:ruleDescription:ListRulesOutput' :: Text
ruleDescription =
Text
pRuleDescription_,
$sel:ruleId:ListRulesOutput' :: Text
ruleId = Text
pRuleId_,
$sel:resourceType:ListRulesOutput' :: Text
resourceType = Text
pResourceType_
}
listRulesOutput_ruleDescription :: Lens.Lens' ListRulesOutput Prelude.Text
listRulesOutput_ruleDescription :: (Text -> f Text) -> ListRulesOutput -> f ListRulesOutput
listRulesOutput_ruleDescription = (ListRulesOutput -> Text)
-> (ListRulesOutput -> Text -> ListRulesOutput)
-> Lens ListRulesOutput ListRulesOutput Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListRulesOutput' {Text
ruleDescription :: Text
$sel:ruleDescription:ListRulesOutput' :: ListRulesOutput -> Text
ruleDescription} -> Text
ruleDescription) (\s :: ListRulesOutput
s@ListRulesOutput' {} Text
a -> ListRulesOutput
s {$sel:ruleDescription:ListRulesOutput' :: Text
ruleDescription = Text
a} :: ListRulesOutput)
listRulesOutput_ruleId :: Lens.Lens' ListRulesOutput Prelude.Text
listRulesOutput_ruleId :: (Text -> f Text) -> ListRulesOutput -> f ListRulesOutput
listRulesOutput_ruleId = (ListRulesOutput -> Text)
-> (ListRulesOutput -> Text -> ListRulesOutput)
-> Lens ListRulesOutput ListRulesOutput Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListRulesOutput' {Text
ruleId :: Text
$sel:ruleId:ListRulesOutput' :: ListRulesOutput -> Text
ruleId} -> Text
ruleId) (\s :: ListRulesOutput
s@ListRulesOutput' {} Text
a -> ListRulesOutput
s {$sel:ruleId:ListRulesOutput' :: Text
ruleId = Text
a} :: ListRulesOutput)
listRulesOutput_resourceType :: Lens.Lens' ListRulesOutput Prelude.Text
listRulesOutput_resourceType :: (Text -> f Text) -> ListRulesOutput -> f ListRulesOutput
listRulesOutput_resourceType = (ListRulesOutput -> Text)
-> (ListRulesOutput -> Text -> ListRulesOutput)
-> Lens ListRulesOutput ListRulesOutput Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListRulesOutput' {Text
resourceType :: Text
$sel:resourceType:ListRulesOutput' :: ListRulesOutput -> Text
resourceType} -> Text
resourceType) (\s :: ListRulesOutput
s@ListRulesOutput' {} Text
a -> ListRulesOutput
s {$sel:resourceType:ListRulesOutput' :: Text
resourceType = Text
a} :: ListRulesOutput)
instance Core.FromJSON ListRulesOutput where
parseJSON :: Value -> Parser ListRulesOutput
parseJSON =
String
-> (Object -> Parser ListRulesOutput)
-> Value
-> Parser ListRulesOutput
forall a. String -> (Object -> Parser a) -> Value -> Parser a
Core.withObject
String
"ListRulesOutput"
( \Object
x ->
Text -> Text -> Text -> ListRulesOutput
ListRulesOutput'
(Text -> Text -> Text -> ListRulesOutput)
-> Parser Text -> Parser (Text -> Text -> ListRulesOutput)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Object
x Object -> Text -> Parser Text
forall a. FromJSON a => Object -> Text -> Parser a
Core..: Text
"ruleDescription")
Parser (Text -> Text -> ListRulesOutput)
-> Parser Text -> Parser (Text -> ListRulesOutput)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser Text
forall a. FromJSON a => Object -> Text -> Parser a
Core..: Text
"ruleId")
Parser (Text -> ListRulesOutput)
-> Parser Text -> Parser ListRulesOutput
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser Text
forall a. FromJSON a => Object -> Text -> Parser a
Core..: Text
"resourceType")
)
instance Prelude.Hashable ListRulesOutput
instance Prelude.NFData ListRulesOutput