module Stratosphere.NetworkFirewall.TLSInspectionConfiguration.TLSInspectionConfigurationProperty (
        module Exports, TLSInspectionConfigurationProperty(..),
        mkTLSInspectionConfigurationProperty
    ) where
import qualified Data.Aeson as JSON
import qualified Stratosphere.Prelude as Prelude
import Stratosphere.Property
import {-# SOURCE #-} Stratosphere.NetworkFirewall.TLSInspectionConfiguration.ServerCertificateConfigurationProperty as Exports
import Stratosphere.ResourceProperties
data TLSInspectionConfigurationProperty
  = -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-networkfirewall-tlsinspectionconfiguration-tlsinspectionconfiguration.html>
    TLSInspectionConfigurationProperty {TLSInspectionConfigurationProperty -> ()
haddock_workaround_ :: (),
                                        -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-networkfirewall-tlsinspectionconfiguration-tlsinspectionconfiguration.html#cfn-networkfirewall-tlsinspectionconfiguration-tlsinspectionconfiguration-servercertificateconfigurations>
                                        TLSInspectionConfigurationProperty
-> Maybe [ServerCertificateConfigurationProperty]
serverCertificateConfigurations :: (Prelude.Maybe [ServerCertificateConfigurationProperty])}
  deriving stock (TLSInspectionConfigurationProperty
-> TLSInspectionConfigurationProperty -> Bool
(TLSInspectionConfigurationProperty
 -> TLSInspectionConfigurationProperty -> Bool)
-> (TLSInspectionConfigurationProperty
    -> TLSInspectionConfigurationProperty -> Bool)
-> Eq TLSInspectionConfigurationProperty
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: TLSInspectionConfigurationProperty
-> TLSInspectionConfigurationProperty -> Bool
== :: TLSInspectionConfigurationProperty
-> TLSInspectionConfigurationProperty -> Bool
$c/= :: TLSInspectionConfigurationProperty
-> TLSInspectionConfigurationProperty -> Bool
/= :: TLSInspectionConfigurationProperty
-> TLSInspectionConfigurationProperty -> Bool
Prelude.Eq, Int -> TLSInspectionConfigurationProperty -> ShowS
[TLSInspectionConfigurationProperty] -> ShowS
TLSInspectionConfigurationProperty -> String
(Int -> TLSInspectionConfigurationProperty -> ShowS)
-> (TLSInspectionConfigurationProperty -> String)
-> ([TLSInspectionConfigurationProperty] -> ShowS)
-> Show TLSInspectionConfigurationProperty
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> TLSInspectionConfigurationProperty -> ShowS
showsPrec :: Int -> TLSInspectionConfigurationProperty -> ShowS
$cshow :: TLSInspectionConfigurationProperty -> String
show :: TLSInspectionConfigurationProperty -> String
$cshowList :: [TLSInspectionConfigurationProperty] -> ShowS
showList :: [TLSInspectionConfigurationProperty] -> ShowS
Prelude.Show)
mkTLSInspectionConfigurationProperty ::
  TLSInspectionConfigurationProperty
mkTLSInspectionConfigurationProperty :: TLSInspectionConfigurationProperty
mkTLSInspectionConfigurationProperty
  = TLSInspectionConfigurationProperty
      {haddock_workaround_ :: ()
haddock_workaround_ = (),
       serverCertificateConfigurations :: Maybe [ServerCertificateConfigurationProperty]
serverCertificateConfigurations = Maybe [ServerCertificateConfigurationProperty]
forall a. Maybe a
Prelude.Nothing}
instance ToResourceProperties TLSInspectionConfigurationProperty where
  toResourceProperties :: TLSInspectionConfigurationProperty -> ResourceProperties
toResourceProperties TLSInspectionConfigurationProperty {Maybe [ServerCertificateConfigurationProperty]
()
haddock_workaround_ :: TLSInspectionConfigurationProperty -> ()
serverCertificateConfigurations :: TLSInspectionConfigurationProperty
-> Maybe [ServerCertificateConfigurationProperty]
haddock_workaround_ :: ()
serverCertificateConfigurations :: Maybe [ServerCertificateConfigurationProperty]
..}
    = ResourceProperties
        {awsType :: Text
awsType = Text
"AWS::NetworkFirewall::TLSInspectionConfiguration.TLSInspectionConfiguration",
         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 -> [ServerCertificateConfigurationProperty] -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"ServerCertificateConfigurations"
                              ([ServerCertificateConfigurationProperty] -> (Key, Value))
-> Maybe [ServerCertificateConfigurationProperty]
-> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe [ServerCertificateConfigurationProperty]
serverCertificateConfigurations])}
instance JSON.ToJSON TLSInspectionConfigurationProperty where
  toJSON :: TLSInspectionConfigurationProperty -> Value
toJSON TLSInspectionConfigurationProperty {Maybe [ServerCertificateConfigurationProperty]
()
haddock_workaround_ :: TLSInspectionConfigurationProperty -> ()
serverCertificateConfigurations :: TLSInspectionConfigurationProperty
-> Maybe [ServerCertificateConfigurationProperty]
haddock_workaround_ :: ()
serverCertificateConfigurations :: Maybe [ServerCertificateConfigurationProperty]
..}
    = [(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 -> [ServerCertificateConfigurationProperty] -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"ServerCertificateConfigurations"
                 ([ServerCertificateConfigurationProperty] -> (Key, Value))
-> Maybe [ServerCertificateConfigurationProperty]
-> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe [ServerCertificateConfigurationProperty]
serverCertificateConfigurations]))
instance Property "ServerCertificateConfigurations" TLSInspectionConfigurationProperty where
  type PropertyType "ServerCertificateConfigurations" TLSInspectionConfigurationProperty = [ServerCertificateConfigurationProperty]
  set :: PropertyType
  "ServerCertificateConfigurations"
  TLSInspectionConfigurationProperty
-> TLSInspectionConfigurationProperty
-> TLSInspectionConfigurationProperty
set PropertyType
  "ServerCertificateConfigurations"
  TLSInspectionConfigurationProperty
newValue TLSInspectionConfigurationProperty {Maybe [ServerCertificateConfigurationProperty]
()
haddock_workaround_ :: TLSInspectionConfigurationProperty -> ()
serverCertificateConfigurations :: TLSInspectionConfigurationProperty
-> Maybe [ServerCertificateConfigurationProperty]
haddock_workaround_ :: ()
serverCertificateConfigurations :: Maybe [ServerCertificateConfigurationProperty]
..}
    = TLSInspectionConfigurationProperty
        {serverCertificateConfigurations :: Maybe [ServerCertificateConfigurationProperty]
serverCertificateConfigurations = [ServerCertificateConfigurationProperty]
-> Maybe [ServerCertificateConfigurationProperty]
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure [ServerCertificateConfigurationProperty]
PropertyType
  "ServerCertificateConfigurations"
  TLSInspectionConfigurationProperty
newValue, ()
haddock_workaround_ :: ()
haddock_workaround_ :: ()
..}