module Stratosphere.Connect.EvaluationForm.EvaluationFormItemProperty (
module Exports, EvaluationFormItemProperty(..),
mkEvaluationFormItemProperty
) where
import qualified Data.Aeson as JSON
import qualified Stratosphere.Prelude as Prelude
import Stratosphere.Property
import {-# SOURCE #-} Stratosphere.Connect.EvaluationForm.EvaluationFormQuestionProperty as Exports
import {-# SOURCE #-} Stratosphere.Connect.EvaluationForm.EvaluationFormSectionProperty as Exports
import Stratosphere.ResourceProperties
data EvaluationFormItemProperty
=
EvaluationFormItemProperty {EvaluationFormItemProperty -> ()
haddock_workaround_ :: (),
EvaluationFormItemProperty -> Maybe EvaluationFormQuestionProperty
question :: (Prelude.Maybe EvaluationFormQuestionProperty),
EvaluationFormItemProperty -> Maybe EvaluationFormSectionProperty
section :: (Prelude.Maybe EvaluationFormSectionProperty)}
deriving stock (EvaluationFormItemProperty -> EvaluationFormItemProperty -> Bool
(EvaluationFormItemProperty -> EvaluationFormItemProperty -> Bool)
-> (EvaluationFormItemProperty
-> EvaluationFormItemProperty -> Bool)
-> Eq EvaluationFormItemProperty
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: EvaluationFormItemProperty -> EvaluationFormItemProperty -> Bool
== :: EvaluationFormItemProperty -> EvaluationFormItemProperty -> Bool
$c/= :: EvaluationFormItemProperty -> EvaluationFormItemProperty -> Bool
/= :: EvaluationFormItemProperty -> EvaluationFormItemProperty -> Bool
Prelude.Eq, Int -> EvaluationFormItemProperty -> ShowS
[EvaluationFormItemProperty] -> ShowS
EvaluationFormItemProperty -> String
(Int -> EvaluationFormItemProperty -> ShowS)
-> (EvaluationFormItemProperty -> String)
-> ([EvaluationFormItemProperty] -> ShowS)
-> Show EvaluationFormItemProperty
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> EvaluationFormItemProperty -> ShowS
showsPrec :: Int -> EvaluationFormItemProperty -> ShowS
$cshow :: EvaluationFormItemProperty -> String
show :: EvaluationFormItemProperty -> String
$cshowList :: [EvaluationFormItemProperty] -> ShowS
showList :: [EvaluationFormItemProperty] -> ShowS
Prelude.Show)
mkEvaluationFormItemProperty :: EvaluationFormItemProperty
mkEvaluationFormItemProperty :: EvaluationFormItemProperty
mkEvaluationFormItemProperty
= EvaluationFormItemProperty
{haddock_workaround_ :: ()
haddock_workaround_ = (), question :: Maybe EvaluationFormQuestionProperty
question = Maybe EvaluationFormQuestionProperty
forall a. Maybe a
Prelude.Nothing,
section :: Maybe EvaluationFormSectionProperty
section = Maybe EvaluationFormSectionProperty
forall a. Maybe a
Prelude.Nothing}
instance ToResourceProperties EvaluationFormItemProperty where
toResourceProperties :: EvaluationFormItemProperty -> ResourceProperties
toResourceProperties EvaluationFormItemProperty {Maybe EvaluationFormQuestionProperty
Maybe EvaluationFormSectionProperty
()
haddock_workaround_ :: EvaluationFormItemProperty -> ()
question :: EvaluationFormItemProperty -> Maybe EvaluationFormQuestionProperty
section :: EvaluationFormItemProperty -> Maybe EvaluationFormSectionProperty
haddock_workaround_ :: ()
question :: Maybe EvaluationFormQuestionProperty
section :: Maybe EvaluationFormSectionProperty
..}
= ResourceProperties
{awsType :: Text
awsType = Text
"AWS::Connect::EvaluationForm.EvaluationFormItem",
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 -> EvaluationFormQuestionProperty -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"Question" (EvaluationFormQuestionProperty -> (Key, Value))
-> Maybe EvaluationFormQuestionProperty -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe EvaluationFormQuestionProperty
question,
Key -> EvaluationFormSectionProperty -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"Section" (EvaluationFormSectionProperty -> (Key, Value))
-> Maybe EvaluationFormSectionProperty -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe EvaluationFormSectionProperty
section])}
instance JSON.ToJSON EvaluationFormItemProperty where
toJSON :: EvaluationFormItemProperty -> Value
toJSON EvaluationFormItemProperty {Maybe EvaluationFormQuestionProperty
Maybe EvaluationFormSectionProperty
()
haddock_workaround_ :: EvaluationFormItemProperty -> ()
question :: EvaluationFormItemProperty -> Maybe EvaluationFormQuestionProperty
section :: EvaluationFormItemProperty -> Maybe EvaluationFormSectionProperty
haddock_workaround_ :: ()
question :: Maybe EvaluationFormQuestionProperty
section :: Maybe EvaluationFormSectionProperty
..}
= [(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 -> EvaluationFormQuestionProperty -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"Question" (EvaluationFormQuestionProperty -> (Key, Value))
-> Maybe EvaluationFormQuestionProperty -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe EvaluationFormQuestionProperty
question,
Key -> EvaluationFormSectionProperty -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"Section" (EvaluationFormSectionProperty -> (Key, Value))
-> Maybe EvaluationFormSectionProperty -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe EvaluationFormSectionProperty
section]))
instance Property "Question" EvaluationFormItemProperty where
type PropertyType "Question" EvaluationFormItemProperty = EvaluationFormQuestionProperty
set :: PropertyType "Question" EvaluationFormItemProperty
-> EvaluationFormItemProperty -> EvaluationFormItemProperty
set PropertyType "Question" EvaluationFormItemProperty
newValue EvaluationFormItemProperty {Maybe EvaluationFormQuestionProperty
Maybe EvaluationFormSectionProperty
()
haddock_workaround_ :: EvaluationFormItemProperty -> ()
question :: EvaluationFormItemProperty -> Maybe EvaluationFormQuestionProperty
section :: EvaluationFormItemProperty -> Maybe EvaluationFormSectionProperty
haddock_workaround_ :: ()
question :: Maybe EvaluationFormQuestionProperty
section :: Maybe EvaluationFormSectionProperty
..}
= EvaluationFormItemProperty {question :: Maybe EvaluationFormQuestionProperty
question = EvaluationFormQuestionProperty
-> Maybe EvaluationFormQuestionProperty
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "Question" EvaluationFormItemProperty
EvaluationFormQuestionProperty
newValue, Maybe EvaluationFormSectionProperty
()
haddock_workaround_ :: ()
section :: Maybe EvaluationFormSectionProperty
haddock_workaround_ :: ()
section :: Maybe EvaluationFormSectionProperty
..}
instance Property "Section" EvaluationFormItemProperty where
type PropertyType "Section" EvaluationFormItemProperty = EvaluationFormSectionProperty
set :: PropertyType "Section" EvaluationFormItemProperty
-> EvaluationFormItemProperty -> EvaluationFormItemProperty
set PropertyType "Section" EvaluationFormItemProperty
newValue EvaluationFormItemProperty {Maybe EvaluationFormQuestionProperty
Maybe EvaluationFormSectionProperty
()
haddock_workaround_ :: EvaluationFormItemProperty -> ()
question :: EvaluationFormItemProperty -> Maybe EvaluationFormQuestionProperty
section :: EvaluationFormItemProperty -> Maybe EvaluationFormSectionProperty
haddock_workaround_ :: ()
question :: Maybe EvaluationFormQuestionProperty
section :: Maybe EvaluationFormSectionProperty
..}
= EvaluationFormItemProperty {section :: Maybe EvaluationFormSectionProperty
section = EvaluationFormSectionProperty
-> Maybe EvaluationFormSectionProperty
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "Section" EvaluationFormItemProperty
EvaluationFormSectionProperty
newValue, Maybe EvaluationFormQuestionProperty
()
haddock_workaround_ :: ()
question :: Maybe EvaluationFormQuestionProperty
haddock_workaround_ :: ()
question :: Maybe EvaluationFormQuestionProperty
..}