{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE DuplicateRecordFields #-}
{-# LANGUAGE NamedFieldPuns #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE StrictData #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# OPTIONS_GHC -fno-warn-unused-binds #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-unused-matches #-}

-- Derived from AWS service descriptions, licensed under Apache 2.0.

-- |
-- Module      : Amazonka.Glue.CreateSecurityConfiguration
-- Copyright   : (c) 2013-2021 Brendan Hay
-- License     : Mozilla Public License, v. 2.0.
-- Maintainer  : Brendan Hay <brendan.g.hay+amazonka@gmail.com>
-- Stability   : auto-generated
-- Portability : non-portable (GHC extensions)
--
-- Creates a new security configuration. A security configuration is a set
-- of security properties that can be used by Glue. You can use a security
-- configuration to encrypt data at rest. For information about using
-- security configurations in Glue, see
-- <https://docs.aws.amazon.com/glue/latest/dg/encryption-security-configuration.html Encrypting Data Written by Crawlers, Jobs, and Development Endpoints>.
module Amazonka.Glue.CreateSecurityConfiguration
  ( -- * Creating a Request
    CreateSecurityConfiguration (..),
    newCreateSecurityConfiguration,

    -- * Request Lenses
    createSecurityConfiguration_name,
    createSecurityConfiguration_encryptionConfiguration,

    -- * Destructuring the Response
    CreateSecurityConfigurationResponse (..),
    newCreateSecurityConfigurationResponse,

    -- * Response Lenses
    createSecurityConfigurationResponse_name,
    createSecurityConfigurationResponse_createdTimestamp,
    createSecurityConfigurationResponse_httpStatus,
  )
where

import qualified Amazonka.Core as Core
import Amazonka.Glue.Types
import qualified Amazonka.Lens as Lens
import qualified Amazonka.Prelude as Prelude
import qualified Amazonka.Request as Request
import qualified Amazonka.Response as Response

-- | /See:/ 'newCreateSecurityConfiguration' smart constructor.
data CreateSecurityConfiguration = CreateSecurityConfiguration'
  { -- | The name for the new security configuration.
    CreateSecurityConfiguration -> Text
name :: Prelude.Text,
    -- | The encryption configuration for the new security configuration.
    CreateSecurityConfiguration -> EncryptionConfiguration
encryptionConfiguration :: EncryptionConfiguration
  }
  deriving (CreateSecurityConfiguration -> CreateSecurityConfiguration -> Bool
(CreateSecurityConfiguration
 -> CreateSecurityConfiguration -> Bool)
-> (CreateSecurityConfiguration
    -> CreateSecurityConfiguration -> Bool)
-> Eq CreateSecurityConfiguration
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: CreateSecurityConfiguration -> CreateSecurityConfiguration -> Bool
$c/= :: CreateSecurityConfiguration -> CreateSecurityConfiguration -> Bool
== :: CreateSecurityConfiguration -> CreateSecurityConfiguration -> Bool
$c== :: CreateSecurityConfiguration -> CreateSecurityConfiguration -> Bool
Prelude.Eq, ReadPrec [CreateSecurityConfiguration]
ReadPrec CreateSecurityConfiguration
Int -> ReadS CreateSecurityConfiguration
ReadS [CreateSecurityConfiguration]
(Int -> ReadS CreateSecurityConfiguration)
-> ReadS [CreateSecurityConfiguration]
-> ReadPrec CreateSecurityConfiguration
-> ReadPrec [CreateSecurityConfiguration]
-> Read CreateSecurityConfiguration
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [CreateSecurityConfiguration]
$creadListPrec :: ReadPrec [CreateSecurityConfiguration]
readPrec :: ReadPrec CreateSecurityConfiguration
$creadPrec :: ReadPrec CreateSecurityConfiguration
readList :: ReadS [CreateSecurityConfiguration]
$creadList :: ReadS [CreateSecurityConfiguration]
readsPrec :: Int -> ReadS CreateSecurityConfiguration
$creadsPrec :: Int -> ReadS CreateSecurityConfiguration
Prelude.Read, Int -> CreateSecurityConfiguration -> ShowS
[CreateSecurityConfiguration] -> ShowS
CreateSecurityConfiguration -> String
(Int -> CreateSecurityConfiguration -> ShowS)
-> (CreateSecurityConfiguration -> String)
-> ([CreateSecurityConfiguration] -> ShowS)
-> Show CreateSecurityConfiguration
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [CreateSecurityConfiguration] -> ShowS
$cshowList :: [CreateSecurityConfiguration] -> ShowS
show :: CreateSecurityConfiguration -> String
$cshow :: CreateSecurityConfiguration -> String
showsPrec :: Int -> CreateSecurityConfiguration -> ShowS
$cshowsPrec :: Int -> CreateSecurityConfiguration -> ShowS
Prelude.Show, (forall x.
 CreateSecurityConfiguration -> Rep CreateSecurityConfiguration x)
-> (forall x.
    Rep CreateSecurityConfiguration x -> CreateSecurityConfiguration)
-> Generic CreateSecurityConfiguration
forall x.
Rep CreateSecurityConfiguration x -> CreateSecurityConfiguration
forall x.
CreateSecurityConfiguration -> Rep CreateSecurityConfiguration x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep CreateSecurityConfiguration x -> CreateSecurityConfiguration
$cfrom :: forall x.
CreateSecurityConfiguration -> Rep CreateSecurityConfiguration x
Prelude.Generic)

-- |
-- Create a value of 'CreateSecurityConfiguration' with all optional fields omitted.
--
-- Use <https://hackage.haskell.org/package/generic-lens generic-lens> or <https://hackage.haskell.org/package/optics optics> to modify other optional fields.
--
-- The following record fields are available, with the corresponding lenses provided
-- for backwards compatibility:
--
-- 'name', 'createSecurityConfiguration_name' - The name for the new security configuration.
--
-- 'encryptionConfiguration', 'createSecurityConfiguration_encryptionConfiguration' - The encryption configuration for the new security configuration.
newCreateSecurityConfiguration ::
  -- | 'name'
  Prelude.Text ->
  -- | 'encryptionConfiguration'
  EncryptionConfiguration ->
  CreateSecurityConfiguration
newCreateSecurityConfiguration :: Text -> EncryptionConfiguration -> CreateSecurityConfiguration
newCreateSecurityConfiguration
  Text
pName_
  EncryptionConfiguration
pEncryptionConfiguration_ =
    CreateSecurityConfiguration' :: Text -> EncryptionConfiguration -> CreateSecurityConfiguration
CreateSecurityConfiguration'
      { $sel:name:CreateSecurityConfiguration' :: Text
name = Text
pName_,
        $sel:encryptionConfiguration:CreateSecurityConfiguration' :: EncryptionConfiguration
encryptionConfiguration =
          EncryptionConfiguration
pEncryptionConfiguration_
      }

-- | The name for the new security configuration.
createSecurityConfiguration_name :: Lens.Lens' CreateSecurityConfiguration Prelude.Text
createSecurityConfiguration_name :: (Text -> f Text)
-> CreateSecurityConfiguration -> f CreateSecurityConfiguration
createSecurityConfiguration_name = (CreateSecurityConfiguration -> Text)
-> (CreateSecurityConfiguration
    -> Text -> CreateSecurityConfiguration)
-> Lens
     CreateSecurityConfiguration CreateSecurityConfiguration Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateSecurityConfiguration' {Text
name :: Text
$sel:name:CreateSecurityConfiguration' :: CreateSecurityConfiguration -> Text
name} -> Text
name) (\s :: CreateSecurityConfiguration
s@CreateSecurityConfiguration' {} Text
a -> CreateSecurityConfiguration
s {$sel:name:CreateSecurityConfiguration' :: Text
name = Text
a} :: CreateSecurityConfiguration)

-- | The encryption configuration for the new security configuration.
createSecurityConfiguration_encryptionConfiguration :: Lens.Lens' CreateSecurityConfiguration EncryptionConfiguration
createSecurityConfiguration_encryptionConfiguration :: (EncryptionConfiguration -> f EncryptionConfiguration)
-> CreateSecurityConfiguration -> f CreateSecurityConfiguration
createSecurityConfiguration_encryptionConfiguration = (CreateSecurityConfiguration -> EncryptionConfiguration)
-> (CreateSecurityConfiguration
    -> EncryptionConfiguration -> CreateSecurityConfiguration)
-> Lens
     CreateSecurityConfiguration
     CreateSecurityConfiguration
     EncryptionConfiguration
     EncryptionConfiguration
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateSecurityConfiguration' {EncryptionConfiguration
encryptionConfiguration :: EncryptionConfiguration
$sel:encryptionConfiguration:CreateSecurityConfiguration' :: CreateSecurityConfiguration -> EncryptionConfiguration
encryptionConfiguration} -> EncryptionConfiguration
encryptionConfiguration) (\s :: CreateSecurityConfiguration
s@CreateSecurityConfiguration' {} EncryptionConfiguration
a -> CreateSecurityConfiguration
s {$sel:encryptionConfiguration:CreateSecurityConfiguration' :: EncryptionConfiguration
encryptionConfiguration = EncryptionConfiguration
a} :: CreateSecurityConfiguration)

instance Core.AWSRequest CreateSecurityConfiguration where
  type
    AWSResponse CreateSecurityConfiguration =
      CreateSecurityConfigurationResponse
  request :: CreateSecurityConfiguration -> Request CreateSecurityConfiguration
request = Service
-> CreateSecurityConfiguration
-> Request CreateSecurityConfiguration
forall a. (ToRequest a, ToJSON a) => Service -> a -> Request a
Request.postJSON Service
defaultService
  response :: Logger
-> Service
-> Proxy CreateSecurityConfiguration
-> ClientResponse ClientBody
-> m (Either
        Error (ClientResponse (AWSResponse CreateSecurityConfiguration)))
response =
    (Int
 -> ResponseHeaders
 -> Object
 -> Either String (AWSResponse CreateSecurityConfiguration))
-> Logger
-> Service
-> Proxy CreateSecurityConfiguration
-> ClientResponse ClientBody
-> m (Either
        Error (ClientResponse (AWSResponse CreateSecurityConfiguration)))
forall (m :: * -> *) a.
MonadResource m =>
(Int -> ResponseHeaders -> Object -> Either String (AWSResponse a))
-> Logger
-> Service
-> Proxy a
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse a)))
Response.receiveJSON
      ( \Int
s ResponseHeaders
h Object
x ->
          Maybe Text
-> Maybe POSIX -> Int -> CreateSecurityConfigurationResponse
CreateSecurityConfigurationResponse'
            (Maybe Text
 -> Maybe POSIX -> Int -> CreateSecurityConfigurationResponse)
-> Either String (Maybe Text)
-> Either
     String (Maybe POSIX -> Int -> CreateSecurityConfigurationResponse)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Object
x Object -> Text -> Either String (Maybe Text)
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"Name")
            Either
  String (Maybe POSIX -> Int -> CreateSecurityConfigurationResponse)
-> Either String (Maybe POSIX)
-> Either String (Int -> CreateSecurityConfigurationResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Either String (Maybe POSIX)
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"CreatedTimestamp")
            Either String (Int -> CreateSecurityConfigurationResponse)
-> Either String Int
-> Either String CreateSecurityConfigurationResponse
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Int -> Either String Int
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure (Int -> Int
forall a. Enum a => a -> Int
Prelude.fromEnum Int
s))
      )

instance Prelude.Hashable CreateSecurityConfiguration

instance Prelude.NFData CreateSecurityConfiguration

instance Core.ToHeaders CreateSecurityConfiguration where
  toHeaders :: CreateSecurityConfiguration -> ResponseHeaders
toHeaders =
    ResponseHeaders -> CreateSecurityConfiguration -> ResponseHeaders
forall a b. a -> b -> a
Prelude.const
      ( [ResponseHeaders] -> ResponseHeaders
forall a. Monoid a => [a] -> a
Prelude.mconcat
          [ HeaderName
"X-Amz-Target"
              HeaderName -> ByteString -> ResponseHeaders
forall a. ToHeader a => HeaderName -> a -> ResponseHeaders
Core.=# ( ByteString
"AWSGlue.CreateSecurityConfiguration" ::
                          Prelude.ByteString
                      ),
            HeaderName
"Content-Type"
              HeaderName -> ByteString -> ResponseHeaders
forall a. ToHeader a => HeaderName -> a -> ResponseHeaders
Core.=# ( ByteString
"application/x-amz-json-1.1" ::
                          Prelude.ByteString
                      )
          ]
      )

instance Core.ToJSON CreateSecurityConfiguration where
  toJSON :: CreateSecurityConfiguration -> Value
toJSON CreateSecurityConfiguration' {Text
EncryptionConfiguration
encryptionConfiguration :: EncryptionConfiguration
name :: Text
$sel:encryptionConfiguration:CreateSecurityConfiguration' :: CreateSecurityConfiguration -> EncryptionConfiguration
$sel:name:CreateSecurityConfiguration' :: CreateSecurityConfiguration -> Text
..} =
    [Pair] -> Value
Core.object
      ( [Maybe Pair] -> [Pair]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
          [ Pair -> Maybe Pair
forall a. a -> Maybe a
Prelude.Just (Text
"Name" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..= Text
name),
            Pair -> Maybe Pair
forall a. a -> Maybe a
Prelude.Just
              ( Text
"EncryptionConfiguration"
                  Text -> EncryptionConfiguration -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..= EncryptionConfiguration
encryptionConfiguration
              )
          ]
      )

instance Core.ToPath CreateSecurityConfiguration where
  toPath :: CreateSecurityConfiguration -> ByteString
toPath = ByteString -> CreateSecurityConfiguration -> ByteString
forall a b. a -> b -> a
Prelude.const ByteString
"/"

instance Core.ToQuery CreateSecurityConfiguration where
  toQuery :: CreateSecurityConfiguration -> QueryString
toQuery = QueryString -> CreateSecurityConfiguration -> QueryString
forall a b. a -> b -> a
Prelude.const QueryString
forall a. Monoid a => a
Prelude.mempty

-- | /See:/ 'newCreateSecurityConfigurationResponse' smart constructor.
data CreateSecurityConfigurationResponse = CreateSecurityConfigurationResponse'
  { -- | The name assigned to the new security configuration.
    CreateSecurityConfigurationResponse -> Maybe Text
name :: Prelude.Maybe Prelude.Text,
    -- | The time at which the new security configuration was created.
    CreateSecurityConfigurationResponse -> Maybe POSIX
createdTimestamp :: Prelude.Maybe Core.POSIX,
    -- | The response's http status code.
    CreateSecurityConfigurationResponse -> Int
httpStatus :: Prelude.Int
  }
  deriving (CreateSecurityConfigurationResponse
-> CreateSecurityConfigurationResponse -> Bool
(CreateSecurityConfigurationResponse
 -> CreateSecurityConfigurationResponse -> Bool)
-> (CreateSecurityConfigurationResponse
    -> CreateSecurityConfigurationResponse -> Bool)
-> Eq CreateSecurityConfigurationResponse
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: CreateSecurityConfigurationResponse
-> CreateSecurityConfigurationResponse -> Bool
$c/= :: CreateSecurityConfigurationResponse
-> CreateSecurityConfigurationResponse -> Bool
== :: CreateSecurityConfigurationResponse
-> CreateSecurityConfigurationResponse -> Bool
$c== :: CreateSecurityConfigurationResponse
-> CreateSecurityConfigurationResponse -> Bool
Prelude.Eq, ReadPrec [CreateSecurityConfigurationResponse]
ReadPrec CreateSecurityConfigurationResponse
Int -> ReadS CreateSecurityConfigurationResponse
ReadS [CreateSecurityConfigurationResponse]
(Int -> ReadS CreateSecurityConfigurationResponse)
-> ReadS [CreateSecurityConfigurationResponse]
-> ReadPrec CreateSecurityConfigurationResponse
-> ReadPrec [CreateSecurityConfigurationResponse]
-> Read CreateSecurityConfigurationResponse
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [CreateSecurityConfigurationResponse]
$creadListPrec :: ReadPrec [CreateSecurityConfigurationResponse]
readPrec :: ReadPrec CreateSecurityConfigurationResponse
$creadPrec :: ReadPrec CreateSecurityConfigurationResponse
readList :: ReadS [CreateSecurityConfigurationResponse]
$creadList :: ReadS [CreateSecurityConfigurationResponse]
readsPrec :: Int -> ReadS CreateSecurityConfigurationResponse
$creadsPrec :: Int -> ReadS CreateSecurityConfigurationResponse
Prelude.Read, Int -> CreateSecurityConfigurationResponse -> ShowS
[CreateSecurityConfigurationResponse] -> ShowS
CreateSecurityConfigurationResponse -> String
(Int -> CreateSecurityConfigurationResponse -> ShowS)
-> (CreateSecurityConfigurationResponse -> String)
-> ([CreateSecurityConfigurationResponse] -> ShowS)
-> Show CreateSecurityConfigurationResponse
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [CreateSecurityConfigurationResponse] -> ShowS
$cshowList :: [CreateSecurityConfigurationResponse] -> ShowS
show :: CreateSecurityConfigurationResponse -> String
$cshow :: CreateSecurityConfigurationResponse -> String
showsPrec :: Int -> CreateSecurityConfigurationResponse -> ShowS
$cshowsPrec :: Int -> CreateSecurityConfigurationResponse -> ShowS
Prelude.Show, (forall x.
 CreateSecurityConfigurationResponse
 -> Rep CreateSecurityConfigurationResponse x)
-> (forall x.
    Rep CreateSecurityConfigurationResponse x
    -> CreateSecurityConfigurationResponse)
-> Generic CreateSecurityConfigurationResponse
forall x.
Rep CreateSecurityConfigurationResponse x
-> CreateSecurityConfigurationResponse
forall x.
CreateSecurityConfigurationResponse
-> Rep CreateSecurityConfigurationResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep CreateSecurityConfigurationResponse x
-> CreateSecurityConfigurationResponse
$cfrom :: forall x.
CreateSecurityConfigurationResponse
-> Rep CreateSecurityConfigurationResponse x
Prelude.Generic)

-- |
-- Create a value of 'CreateSecurityConfigurationResponse' with all optional fields omitted.
--
-- Use <https://hackage.haskell.org/package/generic-lens generic-lens> or <https://hackage.haskell.org/package/optics optics> to modify other optional fields.
--
-- The following record fields are available, with the corresponding lenses provided
-- for backwards compatibility:
--
-- 'name', 'createSecurityConfigurationResponse_name' - The name assigned to the new security configuration.
--
-- 'createdTimestamp', 'createSecurityConfigurationResponse_createdTimestamp' - The time at which the new security configuration was created.
--
-- 'httpStatus', 'createSecurityConfigurationResponse_httpStatus' - The response's http status code.
newCreateSecurityConfigurationResponse ::
  -- | 'httpStatus'
  Prelude.Int ->
  CreateSecurityConfigurationResponse
newCreateSecurityConfigurationResponse :: Int -> CreateSecurityConfigurationResponse
newCreateSecurityConfigurationResponse Int
pHttpStatus_ =
  CreateSecurityConfigurationResponse' :: Maybe Text
-> Maybe POSIX -> Int -> CreateSecurityConfigurationResponse
CreateSecurityConfigurationResponse'
    { $sel:name:CreateSecurityConfigurationResponse' :: Maybe Text
name =
        Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:createdTimestamp:CreateSecurityConfigurationResponse' :: Maybe POSIX
createdTimestamp = Maybe POSIX
forall a. Maybe a
Prelude.Nothing,
      $sel:httpStatus:CreateSecurityConfigurationResponse' :: Int
httpStatus = Int
pHttpStatus_
    }

-- | The name assigned to the new security configuration.
createSecurityConfigurationResponse_name :: Lens.Lens' CreateSecurityConfigurationResponse (Prelude.Maybe Prelude.Text)
createSecurityConfigurationResponse_name :: (Maybe Text -> f (Maybe Text))
-> CreateSecurityConfigurationResponse
-> f CreateSecurityConfigurationResponse
createSecurityConfigurationResponse_name = (CreateSecurityConfigurationResponse -> Maybe Text)
-> (CreateSecurityConfigurationResponse
    -> Maybe Text -> CreateSecurityConfigurationResponse)
-> Lens
     CreateSecurityConfigurationResponse
     CreateSecurityConfigurationResponse
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateSecurityConfigurationResponse' {Maybe Text
name :: Maybe Text
$sel:name:CreateSecurityConfigurationResponse' :: CreateSecurityConfigurationResponse -> Maybe Text
name} -> Maybe Text
name) (\s :: CreateSecurityConfigurationResponse
s@CreateSecurityConfigurationResponse' {} Maybe Text
a -> CreateSecurityConfigurationResponse
s {$sel:name:CreateSecurityConfigurationResponse' :: Maybe Text
name = Maybe Text
a} :: CreateSecurityConfigurationResponse)

-- | The time at which the new security configuration was created.
createSecurityConfigurationResponse_createdTimestamp :: Lens.Lens' CreateSecurityConfigurationResponse (Prelude.Maybe Prelude.UTCTime)
createSecurityConfigurationResponse_createdTimestamp :: (Maybe UTCTime -> f (Maybe UTCTime))
-> CreateSecurityConfigurationResponse
-> f CreateSecurityConfigurationResponse
createSecurityConfigurationResponse_createdTimestamp = (CreateSecurityConfigurationResponse -> Maybe POSIX)
-> (CreateSecurityConfigurationResponse
    -> Maybe POSIX -> CreateSecurityConfigurationResponse)
-> Lens
     CreateSecurityConfigurationResponse
     CreateSecurityConfigurationResponse
     (Maybe POSIX)
     (Maybe POSIX)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateSecurityConfigurationResponse' {Maybe POSIX
createdTimestamp :: Maybe POSIX
$sel:createdTimestamp:CreateSecurityConfigurationResponse' :: CreateSecurityConfigurationResponse -> Maybe POSIX
createdTimestamp} -> Maybe POSIX
createdTimestamp) (\s :: CreateSecurityConfigurationResponse
s@CreateSecurityConfigurationResponse' {} Maybe POSIX
a -> CreateSecurityConfigurationResponse
s {$sel:createdTimestamp:CreateSecurityConfigurationResponse' :: Maybe POSIX
createdTimestamp = Maybe POSIX
a} :: CreateSecurityConfigurationResponse) ((Maybe POSIX -> f (Maybe POSIX))
 -> CreateSecurityConfigurationResponse
 -> f CreateSecurityConfigurationResponse)
-> ((Maybe UTCTime -> f (Maybe UTCTime))
    -> Maybe POSIX -> f (Maybe POSIX))
-> (Maybe UTCTime -> f (Maybe UTCTime))
-> CreateSecurityConfigurationResponse
-> f CreateSecurityConfigurationResponse
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso POSIX POSIX UTCTime UTCTime
-> Iso (Maybe POSIX) (Maybe POSIX) (Maybe UTCTime) (Maybe UTCTime)
forall (f :: * -> *) (g :: * -> *) s t a b.
(Functor f, Functor g) =>
AnIso s t a b -> Iso (f s) (g t) (f a) (g b)
Lens.mapping AnIso POSIX POSIX UTCTime UTCTime
forall (a :: Format). Iso' (Time a) UTCTime
Core._Time

-- | The response's http status code.
createSecurityConfigurationResponse_httpStatus :: Lens.Lens' CreateSecurityConfigurationResponse Prelude.Int
createSecurityConfigurationResponse_httpStatus :: (Int -> f Int)
-> CreateSecurityConfigurationResponse
-> f CreateSecurityConfigurationResponse
createSecurityConfigurationResponse_httpStatus = (CreateSecurityConfigurationResponse -> Int)
-> (CreateSecurityConfigurationResponse
    -> Int -> CreateSecurityConfigurationResponse)
-> Lens
     CreateSecurityConfigurationResponse
     CreateSecurityConfigurationResponse
     Int
     Int
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateSecurityConfigurationResponse' {Int
httpStatus :: Int
$sel:httpStatus:CreateSecurityConfigurationResponse' :: CreateSecurityConfigurationResponse -> Int
httpStatus} -> Int
httpStatus) (\s :: CreateSecurityConfigurationResponse
s@CreateSecurityConfigurationResponse' {} Int
a -> CreateSecurityConfigurationResponse
s {$sel:httpStatus:CreateSecurityConfigurationResponse' :: Int
httpStatus = Int
a} :: CreateSecurityConfigurationResponse)

instance
  Prelude.NFData
    CreateSecurityConfigurationResponse