module Stratosphere.SageMaker.NotebookInstanceLifecycleConfig.NotebookInstanceLifecycleHookProperty (
NotebookInstanceLifecycleHookProperty(..),
mkNotebookInstanceLifecycleHookProperty
) where
import qualified Data.Aeson as JSON
import qualified Stratosphere.Prelude as Prelude
import Stratosphere.Property
import Stratosphere.ResourceProperties
import Stratosphere.Value
data NotebookInstanceLifecycleHookProperty
=
NotebookInstanceLifecycleHookProperty {NotebookInstanceLifecycleHookProperty -> ()
haddock_workaround_ :: (),
NotebookInstanceLifecycleHookProperty -> Maybe (Value Text)
content :: (Prelude.Maybe (Value Prelude.Text))}
deriving stock (NotebookInstanceLifecycleHookProperty
-> NotebookInstanceLifecycleHookProperty -> Bool
(NotebookInstanceLifecycleHookProperty
-> NotebookInstanceLifecycleHookProperty -> Bool)
-> (NotebookInstanceLifecycleHookProperty
-> NotebookInstanceLifecycleHookProperty -> Bool)
-> Eq NotebookInstanceLifecycleHookProperty
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: NotebookInstanceLifecycleHookProperty
-> NotebookInstanceLifecycleHookProperty -> Bool
== :: NotebookInstanceLifecycleHookProperty
-> NotebookInstanceLifecycleHookProperty -> Bool
$c/= :: NotebookInstanceLifecycleHookProperty
-> NotebookInstanceLifecycleHookProperty -> Bool
/= :: NotebookInstanceLifecycleHookProperty
-> NotebookInstanceLifecycleHookProperty -> Bool
Prelude.Eq, Int -> NotebookInstanceLifecycleHookProperty -> ShowS
[NotebookInstanceLifecycleHookProperty] -> ShowS
NotebookInstanceLifecycleHookProperty -> String
(Int -> NotebookInstanceLifecycleHookProperty -> ShowS)
-> (NotebookInstanceLifecycleHookProperty -> String)
-> ([NotebookInstanceLifecycleHookProperty] -> ShowS)
-> Show NotebookInstanceLifecycleHookProperty
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> NotebookInstanceLifecycleHookProperty -> ShowS
showsPrec :: Int -> NotebookInstanceLifecycleHookProperty -> ShowS
$cshow :: NotebookInstanceLifecycleHookProperty -> String
show :: NotebookInstanceLifecycleHookProperty -> String
$cshowList :: [NotebookInstanceLifecycleHookProperty] -> ShowS
showList :: [NotebookInstanceLifecycleHookProperty] -> ShowS
Prelude.Show)
mkNotebookInstanceLifecycleHookProperty ::
NotebookInstanceLifecycleHookProperty
mkNotebookInstanceLifecycleHookProperty :: NotebookInstanceLifecycleHookProperty
mkNotebookInstanceLifecycleHookProperty
= NotebookInstanceLifecycleHookProperty
{haddock_workaround_ :: ()
haddock_workaround_ = (), content :: Maybe (Value Text)
content = Maybe (Value Text)
forall a. Maybe a
Prelude.Nothing}
instance ToResourceProperties NotebookInstanceLifecycleHookProperty where
toResourceProperties :: NotebookInstanceLifecycleHookProperty -> ResourceProperties
toResourceProperties NotebookInstanceLifecycleHookProperty {Maybe (Value Text)
()
haddock_workaround_ :: NotebookInstanceLifecycleHookProperty -> ()
content :: NotebookInstanceLifecycleHookProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
content :: Maybe (Value Text)
..}
= ResourceProperties
{awsType :: Text
awsType = Text
"AWS::SageMaker::NotebookInstanceLifecycleConfig.NotebookInstanceLifecycleHook",
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
"Content" (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)
content])}
instance JSON.ToJSON NotebookInstanceLifecycleHookProperty where
toJSON :: NotebookInstanceLifecycleHookProperty -> Value
toJSON NotebookInstanceLifecycleHookProperty {Maybe (Value Text)
()
haddock_workaround_ :: NotebookInstanceLifecycleHookProperty -> ()
content :: NotebookInstanceLifecycleHookProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
content :: 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
"Content" (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)
content]))
instance Property "Content" NotebookInstanceLifecycleHookProperty where
type PropertyType "Content" NotebookInstanceLifecycleHookProperty = Value Prelude.Text
set :: PropertyType "Content" NotebookInstanceLifecycleHookProperty
-> NotebookInstanceLifecycleHookProperty
-> NotebookInstanceLifecycleHookProperty
set PropertyType "Content" NotebookInstanceLifecycleHookProperty
newValue NotebookInstanceLifecycleHookProperty {Maybe (Value Text)
()
haddock_workaround_ :: NotebookInstanceLifecycleHookProperty -> ()
content :: NotebookInstanceLifecycleHookProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
content :: Maybe (Value Text)
..}
= NotebookInstanceLifecycleHookProperty
{content :: Maybe (Value Text)
content = Value Text -> Maybe (Value Text)
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "Content" NotebookInstanceLifecycleHookProperty
Value Text
newValue, ()
haddock_workaround_ :: ()
haddock_workaround_ :: ()
..}