module Stratosphere.IoTFleetWise.Campaign.SignalInformationProperty (
        SignalInformationProperty(..), mkSignalInformationProperty
    ) where
import qualified Data.Aeson as JSON
import qualified Stratosphere.Prelude as Prelude
import Stratosphere.Property
import Stratosphere.ResourceProperties
import Stratosphere.Value
data SignalInformationProperty
  = -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-iotfleetwise-campaign-signalinformation.html>
    SignalInformationProperty {SignalInformationProperty -> ()
haddock_workaround_ :: (),
                               -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-iotfleetwise-campaign-signalinformation.html#cfn-iotfleetwise-campaign-signalinformation-datapartitionid>
                               SignalInformationProperty -> Maybe (Value Text)
dataPartitionId :: (Prelude.Maybe (Value Prelude.Text)),
                               -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-iotfleetwise-campaign-signalinformation.html#cfn-iotfleetwise-campaign-signalinformation-maxsamplecount>
                               SignalInformationProperty -> Maybe (Value Double)
maxSampleCount :: (Prelude.Maybe (Value Prelude.Double)),
                               -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-iotfleetwise-campaign-signalinformation.html#cfn-iotfleetwise-campaign-signalinformation-minimumsamplingintervalms>
                               SignalInformationProperty -> Maybe (Value Double)
minimumSamplingIntervalMs :: (Prelude.Maybe (Value Prelude.Double)),
                               -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-iotfleetwise-campaign-signalinformation.html#cfn-iotfleetwise-campaign-signalinformation-name>
                               SignalInformationProperty -> Value Text
name :: (Value Prelude.Text)}
  deriving stock (SignalInformationProperty -> SignalInformationProperty -> Bool
(SignalInformationProperty -> SignalInformationProperty -> Bool)
-> (SignalInformationProperty -> SignalInformationProperty -> Bool)
-> Eq SignalInformationProperty
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: SignalInformationProperty -> SignalInformationProperty -> Bool
== :: SignalInformationProperty -> SignalInformationProperty -> Bool
$c/= :: SignalInformationProperty -> SignalInformationProperty -> Bool
/= :: SignalInformationProperty -> SignalInformationProperty -> Bool
Prelude.Eq, Int -> SignalInformationProperty -> ShowS
[SignalInformationProperty] -> ShowS
SignalInformationProperty -> String
(Int -> SignalInformationProperty -> ShowS)
-> (SignalInformationProperty -> String)
-> ([SignalInformationProperty] -> ShowS)
-> Show SignalInformationProperty
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> SignalInformationProperty -> ShowS
showsPrec :: Int -> SignalInformationProperty -> ShowS
$cshow :: SignalInformationProperty -> String
show :: SignalInformationProperty -> String
$cshowList :: [SignalInformationProperty] -> ShowS
showList :: [SignalInformationProperty] -> ShowS
Prelude.Show)
mkSignalInformationProperty ::
  Value Prelude.Text -> SignalInformationProperty
mkSignalInformationProperty :: Value Text -> SignalInformationProperty
mkSignalInformationProperty Value Text
name
  = SignalInformationProperty
      {haddock_workaround_ :: ()
haddock_workaround_ = (), name :: Value Text
name = Value Text
name,
       dataPartitionId :: Maybe (Value Text)
dataPartitionId = Maybe (Value Text)
forall a. Maybe a
Prelude.Nothing,
       maxSampleCount :: Maybe (Value Double)
maxSampleCount = Maybe (Value Double)
forall a. Maybe a
Prelude.Nothing,
       minimumSamplingIntervalMs :: Maybe (Value Double)
minimumSamplingIntervalMs = Maybe (Value Double)
forall a. Maybe a
Prelude.Nothing}
instance ToResourceProperties SignalInformationProperty where
  toResourceProperties :: SignalInformationProperty -> ResourceProperties
toResourceProperties SignalInformationProperty {Maybe (Value Double)
Maybe (Value Text)
()
Value Text
haddock_workaround_ :: SignalInformationProperty -> ()
dataPartitionId :: SignalInformationProperty -> Maybe (Value Text)
maxSampleCount :: SignalInformationProperty -> Maybe (Value Double)
minimumSamplingIntervalMs :: SignalInformationProperty -> Maybe (Value Double)
name :: SignalInformationProperty -> Value Text
haddock_workaround_ :: ()
dataPartitionId :: Maybe (Value Text)
maxSampleCount :: Maybe (Value Double)
minimumSamplingIntervalMs :: Maybe (Value Double)
name :: Value Text
..}
    = ResourceProperties
        {awsType :: Text
awsType = Text
"AWS::IoTFleetWise::Campaign.SignalInformation",
         supportsTags :: Bool
supportsTags = Bool
Prelude.False,
         properties :: Object
properties = [Item Object] -> Object
forall l. IsList l => [Item l] -> l
Prelude.fromList
                        ([(Key, Value)] -> [(Key, Value)] -> [(Key, Value)]
forall a. Semigroup a => a -> a -> a
(Prelude.<>)
                           [Key
"Name" 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
name]
                           ([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
"DataPartitionId" (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)
dataPartitionId,
                               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..=) Key
"MaxSampleCount" (Value Double -> (Key, Value))
-> Maybe (Value Double) -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (Value Double)
maxSampleCount,
                               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..=) Key
"MinimumSamplingIntervalMs"
                                 (Value Double -> (Key, Value))
-> Maybe (Value Double) -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (Value Double)
minimumSamplingIntervalMs]))}
instance JSON.ToJSON SignalInformationProperty where
  toJSON :: SignalInformationProperty -> Value
toJSON SignalInformationProperty {Maybe (Value Double)
Maybe (Value Text)
()
Value Text
haddock_workaround_ :: SignalInformationProperty -> ()
dataPartitionId :: SignalInformationProperty -> Maybe (Value Text)
maxSampleCount :: SignalInformationProperty -> Maybe (Value Double)
minimumSamplingIntervalMs :: SignalInformationProperty -> Maybe (Value Double)
name :: SignalInformationProperty -> Value Text
haddock_workaround_ :: ()
dataPartitionId :: Maybe (Value Text)
maxSampleCount :: Maybe (Value Double)
minimumSamplingIntervalMs :: Maybe (Value Double)
name :: Value Text
..}
    = [(Key, Value)] -> Value
JSON.object
        ([Item [(Key, Value)]] -> [(Key, Value)]
forall l. IsList l => [Item l] -> l
Prelude.fromList
           ([(Key, Value)] -> [(Key, Value)] -> [(Key, Value)]
forall a. Semigroup a => a -> a -> a
(Prelude.<>)
              [Key
"Name" 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
name]
              ([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
"DataPartitionId" (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)
dataPartitionId,
                  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..=) Key
"MaxSampleCount" (Value Double -> (Key, Value))
-> Maybe (Value Double) -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (Value Double)
maxSampleCount,
                  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..=) Key
"MinimumSamplingIntervalMs"
                    (Value Double -> (Key, Value))
-> Maybe (Value Double) -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (Value Double)
minimumSamplingIntervalMs])))
instance Property "DataPartitionId" SignalInformationProperty where
  type PropertyType "DataPartitionId" SignalInformationProperty = Value Prelude.Text
  set :: PropertyType "DataPartitionId" SignalInformationProperty
-> SignalInformationProperty -> SignalInformationProperty
set PropertyType "DataPartitionId" SignalInformationProperty
newValue SignalInformationProperty {Maybe (Value Double)
Maybe (Value Text)
()
Value Text
haddock_workaround_ :: SignalInformationProperty -> ()
dataPartitionId :: SignalInformationProperty -> Maybe (Value Text)
maxSampleCount :: SignalInformationProperty -> Maybe (Value Double)
minimumSamplingIntervalMs :: SignalInformationProperty -> Maybe (Value Double)
name :: SignalInformationProperty -> Value Text
haddock_workaround_ :: ()
dataPartitionId :: Maybe (Value Text)
maxSampleCount :: Maybe (Value Double)
minimumSamplingIntervalMs :: Maybe (Value Double)
name :: Value Text
..}
    = SignalInformationProperty
        {dataPartitionId :: Maybe (Value Text)
dataPartitionId = Value Text -> Maybe (Value Text)
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "DataPartitionId" SignalInformationProperty
Value Text
newValue, Maybe (Value Double)
()
Value Text
haddock_workaround_ :: ()
maxSampleCount :: Maybe (Value Double)
minimumSamplingIntervalMs :: Maybe (Value Double)
name :: Value Text
haddock_workaround_ :: ()
maxSampleCount :: Maybe (Value Double)
minimumSamplingIntervalMs :: Maybe (Value Double)
name :: Value Text
..}
instance Property "MaxSampleCount" SignalInformationProperty where
  type PropertyType "MaxSampleCount" SignalInformationProperty = Value Prelude.Double
  set :: PropertyType "MaxSampleCount" SignalInformationProperty
-> SignalInformationProperty -> SignalInformationProperty
set PropertyType "MaxSampleCount" SignalInformationProperty
newValue SignalInformationProperty {Maybe (Value Double)
Maybe (Value Text)
()
Value Text
haddock_workaround_ :: SignalInformationProperty -> ()
dataPartitionId :: SignalInformationProperty -> Maybe (Value Text)
maxSampleCount :: SignalInformationProperty -> Maybe (Value Double)
minimumSamplingIntervalMs :: SignalInformationProperty -> Maybe (Value Double)
name :: SignalInformationProperty -> Value Text
haddock_workaround_ :: ()
dataPartitionId :: Maybe (Value Text)
maxSampleCount :: Maybe (Value Double)
minimumSamplingIntervalMs :: Maybe (Value Double)
name :: Value Text
..}
    = SignalInformationProperty
        {maxSampleCount :: Maybe (Value Double)
maxSampleCount = Value Double -> Maybe (Value Double)
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "MaxSampleCount" SignalInformationProperty
Value Double
newValue, Maybe (Value Double)
Maybe (Value Text)
()
Value Text
haddock_workaround_ :: ()
dataPartitionId :: Maybe (Value Text)
minimumSamplingIntervalMs :: Maybe (Value Double)
name :: Value Text
haddock_workaround_ :: ()
dataPartitionId :: Maybe (Value Text)
minimumSamplingIntervalMs :: Maybe (Value Double)
name :: Value Text
..}
instance Property "MinimumSamplingIntervalMs" SignalInformationProperty where
  type PropertyType "MinimumSamplingIntervalMs" SignalInformationProperty = Value Prelude.Double
  set :: PropertyType "MinimumSamplingIntervalMs" SignalInformationProperty
-> SignalInformationProperty -> SignalInformationProperty
set PropertyType "MinimumSamplingIntervalMs" SignalInformationProperty
newValue SignalInformationProperty {Maybe (Value Double)
Maybe (Value Text)
()
Value Text
haddock_workaround_ :: SignalInformationProperty -> ()
dataPartitionId :: SignalInformationProperty -> Maybe (Value Text)
maxSampleCount :: SignalInformationProperty -> Maybe (Value Double)
minimumSamplingIntervalMs :: SignalInformationProperty -> Maybe (Value Double)
name :: SignalInformationProperty -> Value Text
haddock_workaround_ :: ()
dataPartitionId :: Maybe (Value Text)
maxSampleCount :: Maybe (Value Double)
minimumSamplingIntervalMs :: Maybe (Value Double)
name :: Value Text
..}
    = SignalInformationProperty
        {minimumSamplingIntervalMs :: Maybe (Value Double)
minimumSamplingIntervalMs = Value Double -> Maybe (Value Double)
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "MinimumSamplingIntervalMs" SignalInformationProperty
Value Double
newValue, Maybe (Value Double)
Maybe (Value Text)
()
Value Text
haddock_workaround_ :: ()
dataPartitionId :: Maybe (Value Text)
maxSampleCount :: Maybe (Value Double)
name :: Value Text
haddock_workaround_ :: ()
dataPartitionId :: Maybe (Value Text)
maxSampleCount :: Maybe (Value Double)
name :: Value Text
..}
instance Property "Name" SignalInformationProperty where
  type PropertyType "Name" SignalInformationProperty = Value Prelude.Text
  set :: PropertyType "Name" SignalInformationProperty
-> SignalInformationProperty -> SignalInformationProperty
set PropertyType "Name" SignalInformationProperty
newValue SignalInformationProperty {Maybe (Value Double)
Maybe (Value Text)
()
Value Text
haddock_workaround_ :: SignalInformationProperty -> ()
dataPartitionId :: SignalInformationProperty -> Maybe (Value Text)
maxSampleCount :: SignalInformationProperty -> Maybe (Value Double)
minimumSamplingIntervalMs :: SignalInformationProperty -> Maybe (Value Double)
name :: SignalInformationProperty -> Value Text
haddock_workaround_ :: ()
dataPartitionId :: Maybe (Value Text)
maxSampleCount :: Maybe (Value Double)
minimumSamplingIntervalMs :: Maybe (Value Double)
name :: Value Text
..}
    = SignalInformationProperty {name :: Value Text
name = PropertyType "Name" SignalInformationProperty
Value Text
newValue, Maybe (Value Double)
Maybe (Value Text)
()
haddock_workaround_ :: ()
dataPartitionId :: Maybe (Value Text)
maxSampleCount :: Maybe (Value Double)
minimumSamplingIntervalMs :: Maybe (Value Double)
haddock_workaround_ :: ()
dataPartitionId :: Maybe (Value Text)
maxSampleCount :: Maybe (Value Double)
minimumSamplingIntervalMs :: Maybe (Value Double)
..}