module Stratosphere.AppMesh.Route.DurationProperty (
DurationProperty(..), mkDurationProperty
) where
import qualified Data.Aeson as JSON
import qualified Stratosphere.Prelude as Prelude
import Stratosphere.Property
import Stratosphere.ResourceProperties
import Stratosphere.Value
data DurationProperty
=
DurationProperty {DurationProperty -> ()
haddock_workaround_ :: (),
DurationProperty -> Value Text
unit :: (Value Prelude.Text),
DurationProperty -> Value Integer
value :: (Value Prelude.Integer)}
deriving stock (DurationProperty -> DurationProperty -> Bool
(DurationProperty -> DurationProperty -> Bool)
-> (DurationProperty -> DurationProperty -> Bool)
-> Eq DurationProperty
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: DurationProperty -> DurationProperty -> Bool
== :: DurationProperty -> DurationProperty -> Bool
$c/= :: DurationProperty -> DurationProperty -> Bool
/= :: DurationProperty -> DurationProperty -> Bool
Prelude.Eq, Int -> DurationProperty -> ShowS
[DurationProperty] -> ShowS
DurationProperty -> String
(Int -> DurationProperty -> ShowS)
-> (DurationProperty -> String)
-> ([DurationProperty] -> ShowS)
-> Show DurationProperty
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> DurationProperty -> ShowS
showsPrec :: Int -> DurationProperty -> ShowS
$cshow :: DurationProperty -> String
show :: DurationProperty -> String
$cshowList :: [DurationProperty] -> ShowS
showList :: [DurationProperty] -> ShowS
Prelude.Show)
mkDurationProperty ::
Value Prelude.Text -> Value Prelude.Integer -> DurationProperty
mkDurationProperty :: Value Text -> Value Integer -> DurationProperty
mkDurationProperty Value Text
unit Value Integer
value
= DurationProperty
{haddock_workaround_ :: ()
haddock_workaround_ = (), unit :: Value Text
unit = Value Text
unit, value :: Value Integer
value = Value Integer
value}
instance ToResourceProperties DurationProperty where
toResourceProperties :: DurationProperty -> ResourceProperties
toResourceProperties DurationProperty {()
Value Integer
Value Text
haddock_workaround_ :: DurationProperty -> ()
unit :: DurationProperty -> Value Text
value :: DurationProperty -> Value Integer
haddock_workaround_ :: ()
unit :: Value Text
value :: Value Integer
..}
= ResourceProperties
{awsType :: Text
awsType = Text
"AWS::AppMesh::Route.Duration",
supportsTags :: Bool
supportsTags = Bool
Prelude.False,
properties :: Object
properties = [Key
"Unit" 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
unit, Key
"Value" Key -> Value Integer -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
JSON..= Value Integer
value]}
instance JSON.ToJSON DurationProperty where
toJSON :: DurationProperty -> Value
toJSON DurationProperty {()
Value Integer
Value Text
haddock_workaround_ :: DurationProperty -> ()
unit :: DurationProperty -> Value Text
value :: DurationProperty -> Value Integer
haddock_workaround_ :: ()
unit :: Value Text
value :: Value Integer
..}
= [(Key, Value)] -> Value
JSON.object [Key
"Unit" 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
unit, Key
"Value" Key -> Value Integer -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
JSON..= Value Integer
value]
instance Property "Unit" DurationProperty where
type PropertyType "Unit" DurationProperty = Value Prelude.Text
set :: PropertyType "Unit" DurationProperty
-> DurationProperty -> DurationProperty
set PropertyType "Unit" DurationProperty
newValue DurationProperty {()
Value Integer
Value Text
haddock_workaround_ :: DurationProperty -> ()
unit :: DurationProperty -> Value Text
value :: DurationProperty -> Value Integer
haddock_workaround_ :: ()
unit :: Value Text
value :: Value Integer
..}
= DurationProperty {unit :: Value Text
unit = PropertyType "Unit" DurationProperty
Value Text
newValue, ()
Value Integer
haddock_workaround_ :: ()
value :: Value Integer
haddock_workaround_ :: ()
value :: Value Integer
..}
instance Property "Value" DurationProperty where
type PropertyType "Value" DurationProperty = Value Prelude.Integer
set :: PropertyType "Value" DurationProperty
-> DurationProperty -> DurationProperty
set PropertyType "Value" DurationProperty
newValue DurationProperty {()
Value Integer
Value Text
haddock_workaround_ :: DurationProperty -> ()
unit :: DurationProperty -> Value Text
value :: DurationProperty -> Value Integer
haddock_workaround_ :: ()
unit :: Value Text
value :: Value Integer
..}
= DurationProperty {value :: Value Integer
value = PropertyType "Value" DurationProperty
Value Integer
newValue, ()
Value Text
haddock_workaround_ :: ()
unit :: Value Text
haddock_workaround_ :: ()
unit :: Value Text
..}