module Stratosphere.Pipes.Pipe.PlacementConstraintProperty (
        PlacementConstraintProperty(..), mkPlacementConstraintProperty
    ) where
import qualified Data.Aeson as JSON
import qualified Stratosphere.Prelude as Prelude
import Stratosphere.Property
import Stratosphere.ResourceProperties
import Stratosphere.Value
data PlacementConstraintProperty
  = -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-pipes-pipe-placementconstraint.html>
    PlacementConstraintProperty {PlacementConstraintProperty -> ()
haddock_workaround_ :: (),
                                 -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-pipes-pipe-placementconstraint.html#cfn-pipes-pipe-placementconstraint-expression>
                                 PlacementConstraintProperty -> Maybe (Value Text)
expression :: (Prelude.Maybe (Value Prelude.Text)),
                                 -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-pipes-pipe-placementconstraint.html#cfn-pipes-pipe-placementconstraint-type>
                                 PlacementConstraintProperty -> Maybe (Value Text)
type' :: (Prelude.Maybe (Value Prelude.Text))}
  deriving stock (PlacementConstraintProperty -> PlacementConstraintProperty -> Bool
(PlacementConstraintProperty
 -> PlacementConstraintProperty -> Bool)
-> (PlacementConstraintProperty
    -> PlacementConstraintProperty -> Bool)
-> Eq PlacementConstraintProperty
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: PlacementConstraintProperty -> PlacementConstraintProperty -> Bool
== :: PlacementConstraintProperty -> PlacementConstraintProperty -> Bool
$c/= :: PlacementConstraintProperty -> PlacementConstraintProperty -> Bool
/= :: PlacementConstraintProperty -> PlacementConstraintProperty -> Bool
Prelude.Eq, Int -> PlacementConstraintProperty -> ShowS
[PlacementConstraintProperty] -> ShowS
PlacementConstraintProperty -> String
(Int -> PlacementConstraintProperty -> ShowS)
-> (PlacementConstraintProperty -> String)
-> ([PlacementConstraintProperty] -> ShowS)
-> Show PlacementConstraintProperty
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> PlacementConstraintProperty -> ShowS
showsPrec :: Int -> PlacementConstraintProperty -> ShowS
$cshow :: PlacementConstraintProperty -> String
show :: PlacementConstraintProperty -> String
$cshowList :: [PlacementConstraintProperty] -> ShowS
showList :: [PlacementConstraintProperty] -> ShowS
Prelude.Show)
mkPlacementConstraintProperty :: PlacementConstraintProperty
mkPlacementConstraintProperty :: PlacementConstraintProperty
mkPlacementConstraintProperty
  = PlacementConstraintProperty
      {haddock_workaround_ :: ()
haddock_workaround_ = (), expression :: Maybe (Value Text)
expression = Maybe (Value Text)
forall a. Maybe a
Prelude.Nothing,
       type' :: Maybe (Value Text)
type' = Maybe (Value Text)
forall a. Maybe a
Prelude.Nothing}
instance ToResourceProperties PlacementConstraintProperty where
  toResourceProperties :: PlacementConstraintProperty -> ResourceProperties
toResourceProperties PlacementConstraintProperty {Maybe (Value Text)
()
haddock_workaround_ :: PlacementConstraintProperty -> ()
expression :: PlacementConstraintProperty -> Maybe (Value Text)
type' :: PlacementConstraintProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
expression :: Maybe (Value Text)
type' :: Maybe (Value Text)
..}
    = ResourceProperties
        {awsType :: Text
awsType = Text
"AWS::Pipes::Pipe.PlacementConstraint",
         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
"Expression" (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)
expression,
                            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
"Type" (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)
type'])}
instance JSON.ToJSON PlacementConstraintProperty where
  toJSON :: PlacementConstraintProperty -> Value
toJSON PlacementConstraintProperty {Maybe (Value Text)
()
haddock_workaround_ :: PlacementConstraintProperty -> ()
expression :: PlacementConstraintProperty -> Maybe (Value Text)
type' :: PlacementConstraintProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
expression :: Maybe (Value Text)
type' :: 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
"Expression" (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)
expression,
               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
"Type" (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)
type']))
instance Property "Expression" PlacementConstraintProperty where
  type PropertyType "Expression" PlacementConstraintProperty = Value Prelude.Text
  set :: PropertyType "Expression" PlacementConstraintProperty
-> PlacementConstraintProperty -> PlacementConstraintProperty
set PropertyType "Expression" PlacementConstraintProperty
newValue PlacementConstraintProperty {Maybe (Value Text)
()
haddock_workaround_ :: PlacementConstraintProperty -> ()
expression :: PlacementConstraintProperty -> Maybe (Value Text)
type' :: PlacementConstraintProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
expression :: Maybe (Value Text)
type' :: Maybe (Value Text)
..}
    = PlacementConstraintProperty
        {expression :: Maybe (Value Text)
expression = Value Text -> Maybe (Value Text)
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "Expression" PlacementConstraintProperty
Value Text
newValue, Maybe (Value Text)
()
haddock_workaround_ :: ()
type' :: Maybe (Value Text)
haddock_workaround_ :: ()
type' :: Maybe (Value Text)
..}
instance Property "Type" PlacementConstraintProperty where
  type PropertyType "Type" PlacementConstraintProperty = Value Prelude.Text
  set :: PropertyType "Type" PlacementConstraintProperty
-> PlacementConstraintProperty -> PlacementConstraintProperty
set PropertyType "Type" PlacementConstraintProperty
newValue PlacementConstraintProperty {Maybe (Value Text)
()
haddock_workaround_ :: PlacementConstraintProperty -> ()
expression :: PlacementConstraintProperty -> Maybe (Value Text)
type' :: PlacementConstraintProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
expression :: Maybe (Value Text)
type' :: Maybe (Value Text)
..}
    = PlacementConstraintProperty {type' :: Maybe (Value Text)
type' = Value Text -> Maybe (Value Text)
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "Type" PlacementConstraintProperty
Value Text
newValue, Maybe (Value Text)
()
haddock_workaround_ :: ()
expression :: Maybe (Value Text)
haddock_workaround_ :: ()
expression :: Maybe (Value Text)
..}