module Stratosphere.B2BI.Transformer.AdvancedOptionsProperty (
        module Exports, AdvancedOptionsProperty(..),
        mkAdvancedOptionsProperty
    ) where
import qualified Data.Aeson as JSON
import qualified Stratosphere.Prelude as Prelude
import Stratosphere.Property
import {-# SOURCE #-} Stratosphere.B2BI.Transformer.X12AdvancedOptionsProperty as Exports
import Stratosphere.ResourceProperties
data AdvancedOptionsProperty
  = -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-b2bi-transformer-advancedoptions.html>
    AdvancedOptionsProperty {AdvancedOptionsProperty -> ()
haddock_workaround_ :: (),
                             -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-b2bi-transformer-advancedoptions.html#cfn-b2bi-transformer-advancedoptions-x12>
                             AdvancedOptionsProperty -> Maybe X12AdvancedOptionsProperty
x12 :: (Prelude.Maybe X12AdvancedOptionsProperty)}
  deriving stock (AdvancedOptionsProperty -> AdvancedOptionsProperty -> Bool
(AdvancedOptionsProperty -> AdvancedOptionsProperty -> Bool)
-> (AdvancedOptionsProperty -> AdvancedOptionsProperty -> Bool)
-> Eq AdvancedOptionsProperty
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: AdvancedOptionsProperty -> AdvancedOptionsProperty -> Bool
== :: AdvancedOptionsProperty -> AdvancedOptionsProperty -> Bool
$c/= :: AdvancedOptionsProperty -> AdvancedOptionsProperty -> Bool
/= :: AdvancedOptionsProperty -> AdvancedOptionsProperty -> Bool
Prelude.Eq, Int -> AdvancedOptionsProperty -> ShowS
[AdvancedOptionsProperty] -> ShowS
AdvancedOptionsProperty -> String
(Int -> AdvancedOptionsProperty -> ShowS)
-> (AdvancedOptionsProperty -> String)
-> ([AdvancedOptionsProperty] -> ShowS)
-> Show AdvancedOptionsProperty
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> AdvancedOptionsProperty -> ShowS
showsPrec :: Int -> AdvancedOptionsProperty -> ShowS
$cshow :: AdvancedOptionsProperty -> String
show :: AdvancedOptionsProperty -> String
$cshowList :: [AdvancedOptionsProperty] -> ShowS
showList :: [AdvancedOptionsProperty] -> ShowS
Prelude.Show)
mkAdvancedOptionsProperty :: AdvancedOptionsProperty
mkAdvancedOptionsProperty :: AdvancedOptionsProperty
mkAdvancedOptionsProperty
  = AdvancedOptionsProperty
      {haddock_workaround_ :: ()
haddock_workaround_ = (), x12 :: Maybe X12AdvancedOptionsProperty
x12 = Maybe X12AdvancedOptionsProperty
forall a. Maybe a
Prelude.Nothing}
instance ToResourceProperties AdvancedOptionsProperty where
  toResourceProperties :: AdvancedOptionsProperty -> ResourceProperties
toResourceProperties AdvancedOptionsProperty {Maybe X12AdvancedOptionsProperty
()
haddock_workaround_ :: AdvancedOptionsProperty -> ()
x12 :: AdvancedOptionsProperty -> Maybe X12AdvancedOptionsProperty
haddock_workaround_ :: ()
x12 :: Maybe X12AdvancedOptionsProperty
..}
    = ResourceProperties
        {awsType :: Text
awsType = Text
"AWS::B2BI::Transformer.AdvancedOptions",
         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 -> X12AdvancedOptionsProperty -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"X12" (X12AdvancedOptionsProperty -> (Key, Value))
-> Maybe X12AdvancedOptionsProperty -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe X12AdvancedOptionsProperty
x12])}
instance JSON.ToJSON AdvancedOptionsProperty where
  toJSON :: AdvancedOptionsProperty -> Value
toJSON AdvancedOptionsProperty {Maybe X12AdvancedOptionsProperty
()
haddock_workaround_ :: AdvancedOptionsProperty -> ()
x12 :: AdvancedOptionsProperty -> Maybe X12AdvancedOptionsProperty
haddock_workaround_ :: ()
x12 :: Maybe X12AdvancedOptionsProperty
..}
    = [(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 -> X12AdvancedOptionsProperty -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"X12" (X12AdvancedOptionsProperty -> (Key, Value))
-> Maybe X12AdvancedOptionsProperty -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe X12AdvancedOptionsProperty
x12]))
instance Property "X12" AdvancedOptionsProperty where
  type PropertyType "X12" AdvancedOptionsProperty = X12AdvancedOptionsProperty
  set :: PropertyType "X12" AdvancedOptionsProperty
-> AdvancedOptionsProperty -> AdvancedOptionsProperty
set PropertyType "X12" AdvancedOptionsProperty
newValue AdvancedOptionsProperty {Maybe X12AdvancedOptionsProperty
()
haddock_workaround_ :: AdvancedOptionsProperty -> ()
x12 :: AdvancedOptionsProperty -> Maybe X12AdvancedOptionsProperty
haddock_workaround_ :: ()
x12 :: Maybe X12AdvancedOptionsProperty
..}
    = AdvancedOptionsProperty {x12 :: Maybe X12AdvancedOptionsProperty
x12 = X12AdvancedOptionsProperty -> Maybe X12AdvancedOptionsProperty
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "X12" AdvancedOptionsProperty
X12AdvancedOptionsProperty
newValue, ()
haddock_workaround_ :: ()
haddock_workaround_ :: ()
..}