module Stratosphere.IoTWireless.WirelessDevice.ApplicationProperty (
ApplicationProperty(..), mkApplicationProperty
) where
import qualified Data.Aeson as JSON
import qualified Stratosphere.Prelude as Prelude
import Stratosphere.Property
import Stratosphere.ResourceProperties
import Stratosphere.Value
data ApplicationProperty
=
ApplicationProperty {ApplicationProperty -> ()
haddock_workaround_ :: (),
ApplicationProperty -> Maybe (Value Text)
destinationName :: (Prelude.Maybe (Value Prelude.Text)),
ApplicationProperty -> Maybe (Value Integer)
fPort :: (Prelude.Maybe (Value Prelude.Integer)),
ApplicationProperty -> Maybe (Value Text)
type' :: (Prelude.Maybe (Value Prelude.Text))}
deriving stock (ApplicationProperty -> ApplicationProperty -> Bool
(ApplicationProperty -> ApplicationProperty -> Bool)
-> (ApplicationProperty -> ApplicationProperty -> Bool)
-> Eq ApplicationProperty
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: ApplicationProperty -> ApplicationProperty -> Bool
== :: ApplicationProperty -> ApplicationProperty -> Bool
$c/= :: ApplicationProperty -> ApplicationProperty -> Bool
/= :: ApplicationProperty -> ApplicationProperty -> Bool
Prelude.Eq, Int -> ApplicationProperty -> ShowS
[ApplicationProperty] -> ShowS
ApplicationProperty -> String
(Int -> ApplicationProperty -> ShowS)
-> (ApplicationProperty -> String)
-> ([ApplicationProperty] -> ShowS)
-> Show ApplicationProperty
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> ApplicationProperty -> ShowS
showsPrec :: Int -> ApplicationProperty -> ShowS
$cshow :: ApplicationProperty -> String
show :: ApplicationProperty -> String
$cshowList :: [ApplicationProperty] -> ShowS
showList :: [ApplicationProperty] -> ShowS
Prelude.Show)
mkApplicationProperty :: ApplicationProperty
mkApplicationProperty :: ApplicationProperty
mkApplicationProperty
= ApplicationProperty
{haddock_workaround_ :: ()
haddock_workaround_ = (), destinationName :: Maybe (Value Text)
destinationName = Maybe (Value Text)
forall a. Maybe a
Prelude.Nothing,
fPort :: Maybe (Value Integer)
fPort = Maybe (Value Integer)
forall a. Maybe a
Prelude.Nothing, type' :: Maybe (Value Text)
type' = Maybe (Value Text)
forall a. Maybe a
Prelude.Nothing}
instance ToResourceProperties ApplicationProperty where
toResourceProperties :: ApplicationProperty -> ResourceProperties
toResourceProperties ApplicationProperty {Maybe (Value Integer)
Maybe (Value Text)
()
haddock_workaround_ :: ApplicationProperty -> ()
destinationName :: ApplicationProperty -> Maybe (Value Text)
fPort :: ApplicationProperty -> Maybe (Value Integer)
type' :: ApplicationProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
destinationName :: Maybe (Value Text)
fPort :: Maybe (Value Integer)
type' :: Maybe (Value Text)
..}
= ResourceProperties
{awsType :: Text
awsType = Text
"AWS::IoTWireless::WirelessDevice.Application",
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
"DestinationName" (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)
destinationName,
Key -> Value Integer -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"FPort" (Value Integer -> (Key, Value))
-> Maybe (Value Integer) -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (Value Integer)
fPort,
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
"Type" (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)
type'])}
instance JSON.ToJSON ApplicationProperty where
toJSON :: ApplicationProperty -> Value
toJSON ApplicationProperty {Maybe (Value Integer)
Maybe (Value Text)
()
haddock_workaround_ :: ApplicationProperty -> ()
destinationName :: ApplicationProperty -> Maybe (Value Text)
fPort :: ApplicationProperty -> Maybe (Value Integer)
type' :: ApplicationProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
destinationName :: Maybe (Value Text)
fPort :: Maybe (Value Integer)
type' :: 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
"DestinationName" (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)
destinationName,
Key -> Value Integer -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"FPort" (Value Integer -> (Key, Value))
-> Maybe (Value Integer) -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (Value Integer)
fPort,
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
"Type" (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)
type']))
instance Property "DestinationName" ApplicationProperty where
type PropertyType "DestinationName" ApplicationProperty = Value Prelude.Text
set :: PropertyType "DestinationName" ApplicationProperty
-> ApplicationProperty -> ApplicationProperty
set PropertyType "DestinationName" ApplicationProperty
newValue ApplicationProperty {Maybe (Value Integer)
Maybe (Value Text)
()
haddock_workaround_ :: ApplicationProperty -> ()
destinationName :: ApplicationProperty -> Maybe (Value Text)
fPort :: ApplicationProperty -> Maybe (Value Integer)
type' :: ApplicationProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
destinationName :: Maybe (Value Text)
fPort :: Maybe (Value Integer)
type' :: Maybe (Value Text)
..}
= ApplicationProperty {destinationName :: Maybe (Value Text)
destinationName = Value Text -> Maybe (Value Text)
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "DestinationName" ApplicationProperty
Value Text
newValue, Maybe (Value Integer)
Maybe (Value Text)
()
haddock_workaround_ :: ()
fPort :: Maybe (Value Integer)
type' :: Maybe (Value Text)
haddock_workaround_ :: ()
fPort :: Maybe (Value Integer)
type' :: Maybe (Value Text)
..}
instance Property "FPort" ApplicationProperty where
type PropertyType "FPort" ApplicationProperty = Value Prelude.Integer
set :: PropertyType "FPort" ApplicationProperty
-> ApplicationProperty -> ApplicationProperty
set PropertyType "FPort" ApplicationProperty
newValue ApplicationProperty {Maybe (Value Integer)
Maybe (Value Text)
()
haddock_workaround_ :: ApplicationProperty -> ()
destinationName :: ApplicationProperty -> Maybe (Value Text)
fPort :: ApplicationProperty -> Maybe (Value Integer)
type' :: ApplicationProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
destinationName :: Maybe (Value Text)
fPort :: Maybe (Value Integer)
type' :: Maybe (Value Text)
..}
= ApplicationProperty {fPort :: Maybe (Value Integer)
fPort = Value Integer -> Maybe (Value Integer)
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "FPort" ApplicationProperty
Value Integer
newValue, Maybe (Value Text)
()
haddock_workaround_ :: ()
destinationName :: Maybe (Value Text)
type' :: Maybe (Value Text)
haddock_workaround_ :: ()
destinationName :: Maybe (Value Text)
type' :: Maybe (Value Text)
..}
instance Property "Type" ApplicationProperty where
type PropertyType "Type" ApplicationProperty = Value Prelude.Text
set :: PropertyType "Type" ApplicationProperty
-> ApplicationProperty -> ApplicationProperty
set PropertyType "Type" ApplicationProperty
newValue ApplicationProperty {Maybe (Value Integer)
Maybe (Value Text)
()
haddock_workaround_ :: ApplicationProperty -> ()
destinationName :: ApplicationProperty -> Maybe (Value Text)
fPort :: ApplicationProperty -> Maybe (Value Integer)
type' :: ApplicationProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
destinationName :: Maybe (Value Text)
fPort :: Maybe (Value Integer)
type' :: Maybe (Value Text)
..}
= ApplicationProperty {type' :: Maybe (Value Text)
type' = Value Text -> Maybe (Value Text)
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "Type" ApplicationProperty
Value Text
newValue, Maybe (Value Integer)
Maybe (Value Text)
()
haddock_workaround_ :: ()
destinationName :: Maybe (Value Text)
fPort :: Maybe (Value Integer)
haddock_workaround_ :: ()
destinationName :: Maybe (Value Text)
fPort :: Maybe (Value Integer)
..}