module Stratosphere.IoTFleetWise.Vehicle.TimePeriodProperty (
        TimePeriodProperty(..), mkTimePeriodProperty
    ) where
import qualified Data.Aeson as JSON
import qualified Stratosphere.Prelude as Prelude
import Stratosphere.Property
import Stratosphere.ResourceProperties
import Stratosphere.Value
data TimePeriodProperty
  = -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-iotfleetwise-vehicle-timeperiod.html>
    TimePeriodProperty {TimePeriodProperty -> ()
haddock_workaround_ :: (),
                        -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-iotfleetwise-vehicle-timeperiod.html#cfn-iotfleetwise-vehicle-timeperiod-unit>
                        TimePeriodProperty -> Value Text
unit :: (Value Prelude.Text),
                        -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-iotfleetwise-vehicle-timeperiod.html#cfn-iotfleetwise-vehicle-timeperiod-value>
                        TimePeriodProperty -> Value Double
value :: (Value Prelude.Double)}
  deriving stock (TimePeriodProperty -> TimePeriodProperty -> Bool
(TimePeriodProperty -> TimePeriodProperty -> Bool)
-> (TimePeriodProperty -> TimePeriodProperty -> Bool)
-> Eq TimePeriodProperty
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: TimePeriodProperty -> TimePeriodProperty -> Bool
== :: TimePeriodProperty -> TimePeriodProperty -> Bool
$c/= :: TimePeriodProperty -> TimePeriodProperty -> Bool
/= :: TimePeriodProperty -> TimePeriodProperty -> Bool
Prelude.Eq, Int -> TimePeriodProperty -> ShowS
[TimePeriodProperty] -> ShowS
TimePeriodProperty -> String
(Int -> TimePeriodProperty -> ShowS)
-> (TimePeriodProperty -> String)
-> ([TimePeriodProperty] -> ShowS)
-> Show TimePeriodProperty
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> TimePeriodProperty -> ShowS
showsPrec :: Int -> TimePeriodProperty -> ShowS
$cshow :: TimePeriodProperty -> String
show :: TimePeriodProperty -> String
$cshowList :: [TimePeriodProperty] -> ShowS
showList :: [TimePeriodProperty] -> ShowS
Prelude.Show)
mkTimePeriodProperty ::
  Value Prelude.Text -> Value Prelude.Double -> TimePeriodProperty
mkTimePeriodProperty :: Value Text -> Value Double -> TimePeriodProperty
mkTimePeriodProperty Value Text
unit Value Double
value
  = TimePeriodProperty
      {haddock_workaround_ :: ()
haddock_workaround_ = (), unit :: Value Text
unit = Value Text
unit, value :: Value Double
value = Value Double
value}
instance ToResourceProperties TimePeriodProperty where
  toResourceProperties :: TimePeriodProperty -> ResourceProperties
toResourceProperties TimePeriodProperty {()
Value Double
Value Text
haddock_workaround_ :: TimePeriodProperty -> ()
unit :: TimePeriodProperty -> Value Text
value :: TimePeriodProperty -> Value Double
haddock_workaround_ :: ()
unit :: Value Text
value :: Value Double
..}
    = ResourceProperties
        {awsType :: Text
awsType = Text
"AWS::IoTFleetWise::Vehicle.TimePeriod",
         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 Double -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
JSON..= Value Double
value]}
instance JSON.ToJSON TimePeriodProperty where
  toJSON :: TimePeriodProperty -> Value
toJSON TimePeriodProperty {()
Value Double
Value Text
haddock_workaround_ :: TimePeriodProperty -> ()
unit :: TimePeriodProperty -> Value Text
value :: TimePeriodProperty -> Value Double
haddock_workaround_ :: ()
unit :: Value Text
value :: Value Double
..}
    = [(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 Double -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
JSON..= Value Double
value]
instance Property "Unit" TimePeriodProperty where
  type PropertyType "Unit" TimePeriodProperty = Value Prelude.Text
  set :: PropertyType "Unit" TimePeriodProperty
-> TimePeriodProperty -> TimePeriodProperty
set PropertyType "Unit" TimePeriodProperty
newValue TimePeriodProperty {()
Value Double
Value Text
haddock_workaround_ :: TimePeriodProperty -> ()
unit :: TimePeriodProperty -> Value Text
value :: TimePeriodProperty -> Value Double
haddock_workaround_ :: ()
unit :: Value Text
value :: Value Double
..}
    = TimePeriodProperty {unit :: Value Text
unit = PropertyType "Unit" TimePeriodProperty
Value Text
newValue, ()
Value Double
haddock_workaround_ :: ()
value :: Value Double
haddock_workaround_ :: ()
value :: Value Double
..}
instance Property "Value" TimePeriodProperty where
  type PropertyType "Value" TimePeriodProperty = Value Prelude.Double
  set :: PropertyType "Value" TimePeriodProperty
-> TimePeriodProperty -> TimePeriodProperty
set PropertyType "Value" TimePeriodProperty
newValue TimePeriodProperty {()
Value Double
Value Text
haddock_workaround_ :: TimePeriodProperty -> ()
unit :: TimePeriodProperty -> Value Text
value :: TimePeriodProperty -> Value Double
haddock_workaround_ :: ()
unit :: Value Text
value :: Value Double
..}
    = TimePeriodProperty {value :: Value Double
value = PropertyType "Value" TimePeriodProperty
Value Double
newValue, ()
Value Text
haddock_workaround_ :: ()
unit :: Value Text
haddock_workaround_ :: ()
unit :: Value Text
..}