module Stratosphere.Route53RecoveryReadiness.ResourceSet.NLBResourceProperty (
        NLBResourceProperty(..), mkNLBResourceProperty
    ) where
import qualified Data.Aeson as JSON
import qualified Stratosphere.Prelude as Prelude
import Stratosphere.Property
import Stratosphere.ResourceProperties
import Stratosphere.Value
data NLBResourceProperty
  = -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-route53recoveryreadiness-resourceset-nlbresource.html>
    NLBResourceProperty {NLBResourceProperty -> ()
haddock_workaround_ :: (),
                         -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-route53recoveryreadiness-resourceset-nlbresource.html#cfn-route53recoveryreadiness-resourceset-nlbresource-arn>
                         NLBResourceProperty -> Maybe (Value Text)
arn :: (Prelude.Maybe (Value Prelude.Text))}
  deriving stock (NLBResourceProperty -> NLBResourceProperty -> Bool
(NLBResourceProperty -> NLBResourceProperty -> Bool)
-> (NLBResourceProperty -> NLBResourceProperty -> Bool)
-> Eq NLBResourceProperty
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: NLBResourceProperty -> NLBResourceProperty -> Bool
== :: NLBResourceProperty -> NLBResourceProperty -> Bool
$c/= :: NLBResourceProperty -> NLBResourceProperty -> Bool
/= :: NLBResourceProperty -> NLBResourceProperty -> Bool
Prelude.Eq, Int -> NLBResourceProperty -> ShowS
[NLBResourceProperty] -> ShowS
NLBResourceProperty -> String
(Int -> NLBResourceProperty -> ShowS)
-> (NLBResourceProperty -> String)
-> ([NLBResourceProperty] -> ShowS)
-> Show NLBResourceProperty
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> NLBResourceProperty -> ShowS
showsPrec :: Int -> NLBResourceProperty -> ShowS
$cshow :: NLBResourceProperty -> String
show :: NLBResourceProperty -> String
$cshowList :: [NLBResourceProperty] -> ShowS
showList :: [NLBResourceProperty] -> ShowS
Prelude.Show)
mkNLBResourceProperty :: NLBResourceProperty
mkNLBResourceProperty :: NLBResourceProperty
mkNLBResourceProperty
  = NLBResourceProperty
      {haddock_workaround_ :: ()
haddock_workaround_ = (), arn :: Maybe (Value Text)
arn = Maybe (Value Text)
forall a. Maybe a
Prelude.Nothing}
instance ToResourceProperties NLBResourceProperty where
  toResourceProperties :: NLBResourceProperty -> ResourceProperties
toResourceProperties NLBResourceProperty {Maybe (Value Text)
()
haddock_workaround_ :: NLBResourceProperty -> ()
arn :: NLBResourceProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
arn :: Maybe (Value Text)
..}
    = ResourceProperties
        {awsType :: Text
awsType = Text
"AWS::Route53RecoveryReadiness::ResourceSet.NLBResource",
         supportsTags :: Bool
supportsTags = Bool
Prelude.False,
         properties :: Object
properties = [Item Object] -> Object
forall l. IsList l => [Item l] -> l
Prelude.fromList
                        ([Maybe (Key, Value)] -> [(Key, Value)]
forall a. [Maybe a] -> [a]
Prelude.catMaybes [Key -> Value Text -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"Arn" (Value Text -> (Key, Value))
-> Maybe (Value Text) -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (Value Text)
arn])}
instance JSON.ToJSON NLBResourceProperty where
  toJSON :: NLBResourceProperty -> Value
toJSON NLBResourceProperty {Maybe (Value Text)
()
haddock_workaround_ :: NLBResourceProperty -> ()
arn :: NLBResourceProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
arn :: Maybe (Value Text)
..}
    = [(Key, Value)] -> Value
JSON.object
        ([Item [(Key, Value)]] -> [(Key, Value)]
forall l. IsList l => [Item l] -> l
Prelude.fromList
           ([Maybe (Key, Value)] -> [(Key, Value)]
forall a. [Maybe a] -> [a]
Prelude.catMaybes [Key -> Value Text -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"Arn" (Value Text -> (Key, Value))
-> Maybe (Value Text) -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (Value Text)
arn]))
instance Property "Arn" NLBResourceProperty where
  type PropertyType "Arn" NLBResourceProperty = Value Prelude.Text
  set :: PropertyType "Arn" NLBResourceProperty
-> NLBResourceProperty -> NLBResourceProperty
set PropertyType "Arn" NLBResourceProperty
newValue NLBResourceProperty {Maybe (Value Text)
()
haddock_workaround_ :: NLBResourceProperty -> ()
arn :: NLBResourceProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
arn :: Maybe (Value Text)
..}
    = NLBResourceProperty {arn :: Maybe (Value Text)
arn = Value Text -> Maybe (Value Text)
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "Arn" NLBResourceProperty
Value Text
newValue, ()
haddock_workaround_ :: ()
haddock_workaround_ :: ()
..}