module Stratosphere.Greengrass.ConnectorDefinition.ConnectorProperty (
ConnectorProperty(..), mkConnectorProperty
) where
import qualified Data.Aeson as JSON
import qualified Stratosphere.Prelude as Prelude
import Stratosphere.Property
import Stratosphere.ResourceProperties
import Stratosphere.Value
data ConnectorProperty
=
ConnectorProperty {ConnectorProperty -> ()
haddock_workaround_ :: (),
ConnectorProperty -> Value Text
connectorArn :: (Value Prelude.Text),
ConnectorProperty -> Value Text
id :: (Value Prelude.Text),
ConnectorProperty -> Maybe Object
parameters :: (Prelude.Maybe JSON.Object)}
deriving stock (ConnectorProperty -> ConnectorProperty -> Bool
(ConnectorProperty -> ConnectorProperty -> Bool)
-> (ConnectorProperty -> ConnectorProperty -> Bool)
-> Eq ConnectorProperty
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: ConnectorProperty -> ConnectorProperty -> Bool
== :: ConnectorProperty -> ConnectorProperty -> Bool
$c/= :: ConnectorProperty -> ConnectorProperty -> Bool
/= :: ConnectorProperty -> ConnectorProperty -> Bool
Prelude.Eq, Int -> ConnectorProperty -> ShowS
[ConnectorProperty] -> ShowS
ConnectorProperty -> String
(Int -> ConnectorProperty -> ShowS)
-> (ConnectorProperty -> String)
-> ([ConnectorProperty] -> ShowS)
-> Show ConnectorProperty
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> ConnectorProperty -> ShowS
showsPrec :: Int -> ConnectorProperty -> ShowS
$cshow :: ConnectorProperty -> String
show :: ConnectorProperty -> String
$cshowList :: [ConnectorProperty] -> ShowS
showList :: [ConnectorProperty] -> ShowS
Prelude.Show)
mkConnectorProperty ::
Value Prelude.Text -> Value Prelude.Text -> ConnectorProperty
mkConnectorProperty :: Value Text -> Value Text -> ConnectorProperty
mkConnectorProperty Value Text
connectorArn Value Text
id
= ConnectorProperty
{haddock_workaround_ :: ()
haddock_workaround_ = (), connectorArn :: Value Text
connectorArn = Value Text
connectorArn, id :: Value Text
id = Value Text
id,
parameters :: Maybe Object
parameters = Maybe Object
forall a. Maybe a
Prelude.Nothing}
instance ToResourceProperties ConnectorProperty where
toResourceProperties :: ConnectorProperty -> ResourceProperties
toResourceProperties ConnectorProperty {Maybe Object
()
Value Text
haddock_workaround_ :: ConnectorProperty -> ()
connectorArn :: ConnectorProperty -> Value Text
id :: ConnectorProperty -> Value Text
parameters :: ConnectorProperty -> Maybe Object
haddock_workaround_ :: ()
connectorArn :: Value Text
id :: Value Text
parameters :: Maybe Object
..}
= ResourceProperties
{awsType :: Text
awsType = Text
"AWS::Greengrass::ConnectorDefinition.Connector",
supportsTags :: Bool
supportsTags = Bool
Prelude.False,
properties :: Object
properties = [Item Object] -> Object
forall l. IsList l => [Item l] -> l
Prelude.fromList
([(Key, Value)] -> [(Key, Value)] -> [(Key, Value)]
forall a. Semigroup a => a -> a -> a
(Prelude.<>)
[Key
"ConnectorArn" 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..= Value Text
connectorArn, Key
"Id" 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..= Value Text
id]
([Maybe (Key, Value)] -> [(Key, Value)]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
[Key -> Object -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"Parameters" (Object -> (Key, Value)) -> Maybe Object -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Object
parameters]))}
instance JSON.ToJSON ConnectorProperty where
toJSON :: ConnectorProperty -> Value
toJSON ConnectorProperty {Maybe Object
()
Value Text
haddock_workaround_ :: ConnectorProperty -> ()
connectorArn :: ConnectorProperty -> Value Text
id :: ConnectorProperty -> Value Text
parameters :: ConnectorProperty -> Maybe Object
haddock_workaround_ :: ()
connectorArn :: Value Text
id :: Value Text
parameters :: Maybe Object
..}
= [(Key, Value)] -> Value
JSON.object
([Item [(Key, Value)]] -> [(Key, Value)]
forall l. IsList l => [Item l] -> l
Prelude.fromList
([(Key, Value)] -> [(Key, Value)] -> [(Key, Value)]
forall a. Semigroup a => a -> a -> a
(Prelude.<>)
[Key
"ConnectorArn" 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..= Value Text
connectorArn, Key
"Id" 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..= Value Text
id]
([Maybe (Key, Value)] -> [(Key, Value)]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
[Key -> Object -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"Parameters" (Object -> (Key, Value)) -> Maybe Object -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Object
parameters])))
instance Property "ConnectorArn" ConnectorProperty where
type PropertyType "ConnectorArn" ConnectorProperty = Value Prelude.Text
set :: PropertyType "ConnectorArn" ConnectorProperty
-> ConnectorProperty -> ConnectorProperty
set PropertyType "ConnectorArn" ConnectorProperty
newValue ConnectorProperty {Maybe Object
()
Value Text
haddock_workaround_ :: ConnectorProperty -> ()
connectorArn :: ConnectorProperty -> Value Text
id :: ConnectorProperty -> Value Text
parameters :: ConnectorProperty -> Maybe Object
haddock_workaround_ :: ()
connectorArn :: Value Text
id :: Value Text
parameters :: Maybe Object
..}
= ConnectorProperty {connectorArn :: Value Text
connectorArn = PropertyType "ConnectorArn" ConnectorProperty
Value Text
newValue, Maybe Object
()
Value Text
haddock_workaround_ :: ()
id :: Value Text
parameters :: Maybe Object
haddock_workaround_ :: ()
id :: Value Text
parameters :: Maybe Object
..}
instance Property "Id" ConnectorProperty where
type PropertyType "Id" ConnectorProperty = Value Prelude.Text
set :: PropertyType "Id" ConnectorProperty
-> ConnectorProperty -> ConnectorProperty
set PropertyType "Id" ConnectorProperty
newValue ConnectorProperty {Maybe Object
()
Value Text
haddock_workaround_ :: ConnectorProperty -> ()
connectorArn :: ConnectorProperty -> Value Text
id :: ConnectorProperty -> Value Text
parameters :: ConnectorProperty -> Maybe Object
haddock_workaround_ :: ()
connectorArn :: Value Text
id :: Value Text
parameters :: Maybe Object
..}
= ConnectorProperty {id :: Value Text
id = PropertyType "Id" ConnectorProperty
Value Text
newValue, Maybe Object
()
Value Text
haddock_workaround_ :: ()
connectorArn :: Value Text
parameters :: Maybe Object
haddock_workaround_ :: ()
connectorArn :: Value Text
parameters :: Maybe Object
..}
instance Property "Parameters" ConnectorProperty where
type PropertyType "Parameters" ConnectorProperty = JSON.Object
set :: PropertyType "Parameters" ConnectorProperty
-> ConnectorProperty -> ConnectorProperty
set PropertyType "Parameters" ConnectorProperty
newValue ConnectorProperty {Maybe Object
()
Value Text
haddock_workaround_ :: ConnectorProperty -> ()
connectorArn :: ConnectorProperty -> Value Text
id :: ConnectorProperty -> Value Text
parameters :: ConnectorProperty -> Maybe Object
haddock_workaround_ :: ()
connectorArn :: Value Text
id :: Value Text
parameters :: Maybe Object
..}
= ConnectorProperty {parameters :: Maybe Object
parameters = Object -> Maybe Object
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure Object
PropertyType "Parameters" ConnectorProperty
newValue, ()
Value Text
haddock_workaround_ :: ()
connectorArn :: Value Text
id :: Value Text
haddock_workaround_ :: ()
connectorArn :: Value Text
id :: Value Text
..}