module Stratosphere.CloudFront.RealtimeLogConfig (
        module Exports, RealtimeLogConfig(..), mkRealtimeLogConfig
    ) where
import qualified Data.Aeson as JSON
import qualified Stratosphere.Prelude as Prelude
import Stratosphere.Property
import {-# SOURCE #-} Stratosphere.CloudFront.RealtimeLogConfig.EndPointProperty as Exports
import Stratosphere.ResourceProperties
import Stratosphere.Value
data RealtimeLogConfig
  = -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-cloudfront-realtimelogconfig.html>
    RealtimeLogConfig {RealtimeLogConfig -> ()
haddock_workaround_ :: (),
                       -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-cloudfront-realtimelogconfig.html#cfn-cloudfront-realtimelogconfig-endpoints>
                       RealtimeLogConfig -> [EndPointProperty]
endPoints :: [EndPointProperty],
                       -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-cloudfront-realtimelogconfig.html#cfn-cloudfront-realtimelogconfig-fields>
                       RealtimeLogConfig -> ValueList Text
fields :: (ValueList Prelude.Text),
                       -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-cloudfront-realtimelogconfig.html#cfn-cloudfront-realtimelogconfig-name>
                       RealtimeLogConfig -> Value Text
name :: (Value Prelude.Text),
                       -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-cloudfront-realtimelogconfig.html#cfn-cloudfront-realtimelogconfig-samplingrate>
                       RealtimeLogConfig -> Value Double
samplingRate :: (Value Prelude.Double)}
  deriving stock (RealtimeLogConfig -> RealtimeLogConfig -> Bool
(RealtimeLogConfig -> RealtimeLogConfig -> Bool)
-> (RealtimeLogConfig -> RealtimeLogConfig -> Bool)
-> Eq RealtimeLogConfig
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: RealtimeLogConfig -> RealtimeLogConfig -> Bool
== :: RealtimeLogConfig -> RealtimeLogConfig -> Bool
$c/= :: RealtimeLogConfig -> RealtimeLogConfig -> Bool
/= :: RealtimeLogConfig -> RealtimeLogConfig -> Bool
Prelude.Eq, Int -> RealtimeLogConfig -> ShowS
[RealtimeLogConfig] -> ShowS
RealtimeLogConfig -> String
(Int -> RealtimeLogConfig -> ShowS)
-> (RealtimeLogConfig -> String)
-> ([RealtimeLogConfig] -> ShowS)
-> Show RealtimeLogConfig
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> RealtimeLogConfig -> ShowS
showsPrec :: Int -> RealtimeLogConfig -> ShowS
$cshow :: RealtimeLogConfig -> String
show :: RealtimeLogConfig -> String
$cshowList :: [RealtimeLogConfig] -> ShowS
showList :: [RealtimeLogConfig] -> ShowS
Prelude.Show)
mkRealtimeLogConfig ::
  [EndPointProperty]
  -> ValueList Prelude.Text
     -> Value Prelude.Text -> Value Prelude.Double -> RealtimeLogConfig
mkRealtimeLogConfig :: [EndPointProperty]
-> ValueList Text
-> Value Text
-> Value Double
-> RealtimeLogConfig
mkRealtimeLogConfig [EndPointProperty]
endPoints ValueList Text
fields Value Text
name Value Double
samplingRate
  = RealtimeLogConfig
      {haddock_workaround_ :: ()
haddock_workaround_ = (), endPoints :: [EndPointProperty]
endPoints = [EndPointProperty]
endPoints, fields :: ValueList Text
fields = ValueList Text
fields,
       name :: Value Text
name = Value Text
name, samplingRate :: Value Double
samplingRate = Value Double
samplingRate}
instance ToResourceProperties RealtimeLogConfig where
  toResourceProperties :: RealtimeLogConfig -> ResourceProperties
toResourceProperties RealtimeLogConfig {[EndPointProperty]
()
ValueList Text
Value Double
Value Text
haddock_workaround_ :: RealtimeLogConfig -> ()
endPoints :: RealtimeLogConfig -> [EndPointProperty]
fields :: RealtimeLogConfig -> ValueList Text
name :: RealtimeLogConfig -> Value Text
samplingRate :: RealtimeLogConfig -> Value Double
haddock_workaround_ :: ()
endPoints :: [EndPointProperty]
fields :: ValueList Text
name :: Value Text
samplingRate :: Value Double
..}
    = ResourceProperties
        {awsType :: Text
awsType = Text
"AWS::CloudFront::RealtimeLogConfig",
         supportsTags :: Bool
supportsTags = Bool
Prelude.False,
         properties :: Object
properties = [Key
"EndPoints" Key -> [EndPointProperty] -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
JSON..= [EndPointProperty]
endPoints,
                       Key
"Fields" Key -> ValueList Text -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
JSON..= ValueList Text
fields, 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,
                       Key
"SamplingRate" 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
samplingRate]}
instance JSON.ToJSON RealtimeLogConfig where
  toJSON :: RealtimeLogConfig -> Value
toJSON RealtimeLogConfig {[EndPointProperty]
()
ValueList Text
Value Double
Value Text
haddock_workaround_ :: RealtimeLogConfig -> ()
endPoints :: RealtimeLogConfig -> [EndPointProperty]
fields :: RealtimeLogConfig -> ValueList Text
name :: RealtimeLogConfig -> Value Text
samplingRate :: RealtimeLogConfig -> Value Double
haddock_workaround_ :: ()
endPoints :: [EndPointProperty]
fields :: ValueList Text
name :: Value Text
samplingRate :: Value Double
..}
    = [(Key, Value)] -> Value
JSON.object
        [Key
"EndPoints" Key -> [EndPointProperty] -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
JSON..= [EndPointProperty]
endPoints, Key
"Fields" Key -> ValueList Text -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
JSON..= ValueList Text
fields,
         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, Key
"SamplingRate" 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
samplingRate]
instance Property "EndPoints" RealtimeLogConfig where
  type PropertyType "EndPoints" RealtimeLogConfig = [EndPointProperty]
  set :: PropertyType "EndPoints" RealtimeLogConfig
-> RealtimeLogConfig -> RealtimeLogConfig
set PropertyType "EndPoints" RealtimeLogConfig
newValue RealtimeLogConfig {[EndPointProperty]
()
ValueList Text
Value Double
Value Text
haddock_workaround_ :: RealtimeLogConfig -> ()
endPoints :: RealtimeLogConfig -> [EndPointProperty]
fields :: RealtimeLogConfig -> ValueList Text
name :: RealtimeLogConfig -> Value Text
samplingRate :: RealtimeLogConfig -> Value Double
haddock_workaround_ :: ()
endPoints :: [EndPointProperty]
fields :: ValueList Text
name :: Value Text
samplingRate :: Value Double
..}
    = RealtimeLogConfig {endPoints :: [EndPointProperty]
endPoints = [EndPointProperty]
PropertyType "EndPoints" RealtimeLogConfig
newValue, ()
ValueList Text
Value Double
Value Text
haddock_workaround_ :: ()
fields :: ValueList Text
name :: Value Text
samplingRate :: Value Double
haddock_workaround_ :: ()
fields :: ValueList Text
name :: Value Text
samplingRate :: Value Double
..}
instance Property "Fields" RealtimeLogConfig where
  type PropertyType "Fields" RealtimeLogConfig = ValueList Prelude.Text
  set :: PropertyType "Fields" RealtimeLogConfig
-> RealtimeLogConfig -> RealtimeLogConfig
set PropertyType "Fields" RealtimeLogConfig
newValue RealtimeLogConfig {[EndPointProperty]
()
ValueList Text
Value Double
Value Text
haddock_workaround_ :: RealtimeLogConfig -> ()
endPoints :: RealtimeLogConfig -> [EndPointProperty]
fields :: RealtimeLogConfig -> ValueList Text
name :: RealtimeLogConfig -> Value Text
samplingRate :: RealtimeLogConfig -> Value Double
haddock_workaround_ :: ()
endPoints :: [EndPointProperty]
fields :: ValueList Text
name :: Value Text
samplingRate :: Value Double
..}
    = RealtimeLogConfig {fields :: ValueList Text
fields = PropertyType "Fields" RealtimeLogConfig
ValueList Text
newValue, [EndPointProperty]
()
Value Double
Value Text
haddock_workaround_ :: ()
endPoints :: [EndPointProperty]
name :: Value Text
samplingRate :: Value Double
haddock_workaround_ :: ()
endPoints :: [EndPointProperty]
name :: Value Text
samplingRate :: Value Double
..}
instance Property "Name" RealtimeLogConfig where
  type PropertyType "Name" RealtimeLogConfig = Value Prelude.Text
  set :: PropertyType "Name" RealtimeLogConfig
-> RealtimeLogConfig -> RealtimeLogConfig
set PropertyType "Name" RealtimeLogConfig
newValue RealtimeLogConfig {[EndPointProperty]
()
ValueList Text
Value Double
Value Text
haddock_workaround_ :: RealtimeLogConfig -> ()
endPoints :: RealtimeLogConfig -> [EndPointProperty]
fields :: RealtimeLogConfig -> ValueList Text
name :: RealtimeLogConfig -> Value Text
samplingRate :: RealtimeLogConfig -> Value Double
haddock_workaround_ :: ()
endPoints :: [EndPointProperty]
fields :: ValueList Text
name :: Value Text
samplingRate :: Value Double
..}
    = RealtimeLogConfig {name :: Value Text
name = PropertyType "Name" RealtimeLogConfig
Value Text
newValue, [EndPointProperty]
()
ValueList Text
Value Double
haddock_workaround_ :: ()
endPoints :: [EndPointProperty]
fields :: ValueList Text
samplingRate :: Value Double
haddock_workaround_ :: ()
endPoints :: [EndPointProperty]
fields :: ValueList Text
samplingRate :: Value Double
..}
instance Property "SamplingRate" RealtimeLogConfig where
  type PropertyType "SamplingRate" RealtimeLogConfig = Value Prelude.Double
  set :: PropertyType "SamplingRate" RealtimeLogConfig
-> RealtimeLogConfig -> RealtimeLogConfig
set PropertyType "SamplingRate" RealtimeLogConfig
newValue RealtimeLogConfig {[EndPointProperty]
()
ValueList Text
Value Double
Value Text
haddock_workaround_ :: RealtimeLogConfig -> ()
endPoints :: RealtimeLogConfig -> [EndPointProperty]
fields :: RealtimeLogConfig -> ValueList Text
name :: RealtimeLogConfig -> Value Text
samplingRate :: RealtimeLogConfig -> Value Double
haddock_workaround_ :: ()
endPoints :: [EndPointProperty]
fields :: ValueList Text
name :: Value Text
samplingRate :: Value Double
..}
    = RealtimeLogConfig {samplingRate :: Value Double
samplingRate = PropertyType "SamplingRate" RealtimeLogConfig
Value Double
newValue, [EndPointProperty]
()
ValueList Text
Value Text
haddock_workaround_ :: ()
endPoints :: [EndPointProperty]
fields :: ValueList Text
name :: Value Text
haddock_workaround_ :: ()
endPoints :: [EndPointProperty]
fields :: ValueList Text
name :: Value Text
..}