module Stratosphere.DataBrew.Recipe.ActionProperty (
module Exports, ActionProperty(..), mkActionProperty
) where
import qualified Data.Aeson as JSON
import qualified Stratosphere.Prelude as Prelude
import Stratosphere.Property
import {-# SOURCE #-} Stratosphere.DataBrew.Recipe.RecipeParametersProperty as Exports
import Stratosphere.ResourceProperties
import Stratosphere.Value
data ActionProperty
=
ActionProperty {ActionProperty -> ()
haddock_workaround_ :: (),
ActionProperty -> Value Text
operation :: (Value Prelude.Text),
ActionProperty -> Maybe RecipeParametersProperty
parameters :: (Prelude.Maybe RecipeParametersProperty)}
deriving stock (ActionProperty -> ActionProperty -> Bool
(ActionProperty -> ActionProperty -> Bool)
-> (ActionProperty -> ActionProperty -> Bool) -> Eq ActionProperty
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: ActionProperty -> ActionProperty -> Bool
== :: ActionProperty -> ActionProperty -> Bool
$c/= :: ActionProperty -> ActionProperty -> Bool
/= :: ActionProperty -> ActionProperty -> Bool
Prelude.Eq, Int -> ActionProperty -> ShowS
[ActionProperty] -> ShowS
ActionProperty -> String
(Int -> ActionProperty -> ShowS)
-> (ActionProperty -> String)
-> ([ActionProperty] -> ShowS)
-> Show ActionProperty
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> ActionProperty -> ShowS
showsPrec :: Int -> ActionProperty -> ShowS
$cshow :: ActionProperty -> String
show :: ActionProperty -> String
$cshowList :: [ActionProperty] -> ShowS
showList :: [ActionProperty] -> ShowS
Prelude.Show)
mkActionProperty :: Value Prelude.Text -> ActionProperty
mkActionProperty :: Value Text -> ActionProperty
mkActionProperty Value Text
operation
= ActionProperty
{haddock_workaround_ :: ()
haddock_workaround_ = (), operation :: Value Text
operation = Value Text
operation,
parameters :: Maybe RecipeParametersProperty
parameters = Maybe RecipeParametersProperty
forall a. Maybe a
Prelude.Nothing}
instance ToResourceProperties ActionProperty where
toResourceProperties :: ActionProperty -> ResourceProperties
toResourceProperties ActionProperty {Maybe RecipeParametersProperty
()
Value Text
haddock_workaround_ :: ActionProperty -> ()
operation :: ActionProperty -> Value Text
parameters :: ActionProperty -> Maybe RecipeParametersProperty
haddock_workaround_ :: ()
operation :: Value Text
parameters :: Maybe RecipeParametersProperty
..}
= ResourceProperties
{awsType :: Text
awsType = Text
"AWS::DataBrew::Recipe.Action",
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
"Operation" 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
operation]
([Maybe (Key, Value)] -> [(Key, Value)]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
[Key -> RecipeParametersProperty -> (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" (RecipeParametersProperty -> (Key, Value))
-> Maybe RecipeParametersProperty -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe RecipeParametersProperty
parameters]))}
instance JSON.ToJSON ActionProperty where
toJSON :: ActionProperty -> Value
toJSON ActionProperty {Maybe RecipeParametersProperty
()
Value Text
haddock_workaround_ :: ActionProperty -> ()
operation :: ActionProperty -> Value Text
parameters :: ActionProperty -> Maybe RecipeParametersProperty
haddock_workaround_ :: ()
operation :: Value Text
parameters :: Maybe RecipeParametersProperty
..}
= [(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
"Operation" 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
operation]
([Maybe (Key, Value)] -> [(Key, Value)]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
[Key -> RecipeParametersProperty -> (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" (RecipeParametersProperty -> (Key, Value))
-> Maybe RecipeParametersProperty -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe RecipeParametersProperty
parameters])))
instance Property "Operation" ActionProperty where
type PropertyType "Operation" ActionProperty = Value Prelude.Text
set :: PropertyType "Operation" ActionProperty
-> ActionProperty -> ActionProperty
set PropertyType "Operation" ActionProperty
newValue ActionProperty {Maybe RecipeParametersProperty
()
Value Text
haddock_workaround_ :: ActionProperty -> ()
operation :: ActionProperty -> Value Text
parameters :: ActionProperty -> Maybe RecipeParametersProperty
haddock_workaround_ :: ()
operation :: Value Text
parameters :: Maybe RecipeParametersProperty
..}
= ActionProperty {operation :: Value Text
operation = PropertyType "Operation" ActionProperty
Value Text
newValue, Maybe RecipeParametersProperty
()
haddock_workaround_ :: ()
parameters :: Maybe RecipeParametersProperty
haddock_workaround_ :: ()
parameters :: Maybe RecipeParametersProperty
..}
instance Property "Parameters" ActionProperty where
type PropertyType "Parameters" ActionProperty = RecipeParametersProperty
set :: PropertyType "Parameters" ActionProperty
-> ActionProperty -> ActionProperty
set PropertyType "Parameters" ActionProperty
newValue ActionProperty {Maybe RecipeParametersProperty
()
Value Text
haddock_workaround_ :: ActionProperty -> ()
operation :: ActionProperty -> Value Text
parameters :: ActionProperty -> Maybe RecipeParametersProperty
haddock_workaround_ :: ()
operation :: Value Text
parameters :: Maybe RecipeParametersProperty
..}
= ActionProperty {parameters :: Maybe RecipeParametersProperty
parameters = RecipeParametersProperty -> Maybe RecipeParametersProperty
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "Parameters" ActionProperty
RecipeParametersProperty
newValue, ()
Value Text
haddock_workaround_ :: ()
operation :: Value Text
haddock_workaround_ :: ()
operation :: Value Text
..}