{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE DuplicateRecordFields #-}
{-# LANGUAGE NamedFieldPuns #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE StrictData #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-unused-matches #-}
module Amazonka.LexModels.Types.BotAliasMetadata where
import qualified Amazonka.Core as Core
import qualified Amazonka.Lens as Lens
import Amazonka.LexModels.Types.ConversationLogsResponse
import qualified Amazonka.Prelude as Prelude
data BotAliasMetadata = BotAliasMetadata'
{
BotAliasMetadata -> Maybe Text
checksum :: Prelude.Maybe Prelude.Text,
BotAliasMetadata -> Maybe Text
botVersion :: Prelude.Maybe Prelude.Text,
BotAliasMetadata -> Maybe Text
botName :: Prelude.Maybe Prelude.Text,
BotAliasMetadata -> Maybe POSIX
createdDate :: Prelude.Maybe Core.POSIX,
BotAliasMetadata -> Maybe Text
name :: Prelude.Maybe Prelude.Text,
BotAliasMetadata -> Maybe ConversationLogsResponse
conversationLogs :: Prelude.Maybe ConversationLogsResponse,
BotAliasMetadata -> Maybe POSIX
lastUpdatedDate :: Prelude.Maybe Core.POSIX,
BotAliasMetadata -> Maybe Text
description :: Prelude.Maybe Prelude.Text
}
deriving (BotAliasMetadata -> BotAliasMetadata -> Bool
(BotAliasMetadata -> BotAliasMetadata -> Bool)
-> (BotAliasMetadata -> BotAliasMetadata -> Bool)
-> Eq BotAliasMetadata
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: BotAliasMetadata -> BotAliasMetadata -> Bool
$c/= :: BotAliasMetadata -> BotAliasMetadata -> Bool
== :: BotAliasMetadata -> BotAliasMetadata -> Bool
$c== :: BotAliasMetadata -> BotAliasMetadata -> Bool
Prelude.Eq, ReadPrec [BotAliasMetadata]
ReadPrec BotAliasMetadata
Int -> ReadS BotAliasMetadata
ReadS [BotAliasMetadata]
(Int -> ReadS BotAliasMetadata)
-> ReadS [BotAliasMetadata]
-> ReadPrec BotAliasMetadata
-> ReadPrec [BotAliasMetadata]
-> Read BotAliasMetadata
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [BotAliasMetadata]
$creadListPrec :: ReadPrec [BotAliasMetadata]
readPrec :: ReadPrec BotAliasMetadata
$creadPrec :: ReadPrec BotAliasMetadata
readList :: ReadS [BotAliasMetadata]
$creadList :: ReadS [BotAliasMetadata]
readsPrec :: Int -> ReadS BotAliasMetadata
$creadsPrec :: Int -> ReadS BotAliasMetadata
Prelude.Read, Int -> BotAliasMetadata -> ShowS
[BotAliasMetadata] -> ShowS
BotAliasMetadata -> String
(Int -> BotAliasMetadata -> ShowS)
-> (BotAliasMetadata -> String)
-> ([BotAliasMetadata] -> ShowS)
-> Show BotAliasMetadata
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [BotAliasMetadata] -> ShowS
$cshowList :: [BotAliasMetadata] -> ShowS
show :: BotAliasMetadata -> String
$cshow :: BotAliasMetadata -> String
showsPrec :: Int -> BotAliasMetadata -> ShowS
$cshowsPrec :: Int -> BotAliasMetadata -> ShowS
Prelude.Show, (forall x. BotAliasMetadata -> Rep BotAliasMetadata x)
-> (forall x. Rep BotAliasMetadata x -> BotAliasMetadata)
-> Generic BotAliasMetadata
forall x. Rep BotAliasMetadata x -> BotAliasMetadata
forall x. BotAliasMetadata -> Rep BotAliasMetadata x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep BotAliasMetadata x -> BotAliasMetadata
$cfrom :: forall x. BotAliasMetadata -> Rep BotAliasMetadata x
Prelude.Generic)
newBotAliasMetadata ::
BotAliasMetadata
newBotAliasMetadata :: BotAliasMetadata
newBotAliasMetadata =
BotAliasMetadata' :: Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe POSIX
-> Maybe Text
-> Maybe ConversationLogsResponse
-> Maybe POSIX
-> Maybe Text
-> BotAliasMetadata
BotAliasMetadata'
{ $sel:checksum:BotAliasMetadata' :: Maybe Text
checksum = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:botVersion:BotAliasMetadata' :: Maybe Text
botVersion = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:botName:BotAliasMetadata' :: Maybe Text
botName = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:createdDate:BotAliasMetadata' :: Maybe POSIX
createdDate = Maybe POSIX
forall a. Maybe a
Prelude.Nothing,
$sel:name:BotAliasMetadata' :: Maybe Text
name = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:conversationLogs:BotAliasMetadata' :: Maybe ConversationLogsResponse
conversationLogs = Maybe ConversationLogsResponse
forall a. Maybe a
Prelude.Nothing,
$sel:lastUpdatedDate:BotAliasMetadata' :: Maybe POSIX
lastUpdatedDate = Maybe POSIX
forall a. Maybe a
Prelude.Nothing,
$sel:description:BotAliasMetadata' :: Maybe Text
description = Maybe Text
forall a. Maybe a
Prelude.Nothing
}
botAliasMetadata_checksum :: Lens.Lens' BotAliasMetadata (Prelude.Maybe Prelude.Text)
botAliasMetadata_checksum :: (Maybe Text -> f (Maybe Text))
-> BotAliasMetadata -> f BotAliasMetadata
botAliasMetadata_checksum = (BotAliasMetadata -> Maybe Text)
-> (BotAliasMetadata -> Maybe Text -> BotAliasMetadata)
-> Lens BotAliasMetadata BotAliasMetadata (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\BotAliasMetadata' {Maybe Text
checksum :: Maybe Text
$sel:checksum:BotAliasMetadata' :: BotAliasMetadata -> Maybe Text
checksum} -> Maybe Text
checksum) (\s :: BotAliasMetadata
s@BotAliasMetadata' {} Maybe Text
a -> BotAliasMetadata
s {$sel:checksum:BotAliasMetadata' :: Maybe Text
checksum = Maybe Text
a} :: BotAliasMetadata)
botAliasMetadata_botVersion :: Lens.Lens' BotAliasMetadata (Prelude.Maybe Prelude.Text)
botAliasMetadata_botVersion :: (Maybe Text -> f (Maybe Text))
-> BotAliasMetadata -> f BotAliasMetadata
botAliasMetadata_botVersion = (BotAliasMetadata -> Maybe Text)
-> (BotAliasMetadata -> Maybe Text -> BotAliasMetadata)
-> Lens BotAliasMetadata BotAliasMetadata (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\BotAliasMetadata' {Maybe Text
botVersion :: Maybe Text
$sel:botVersion:BotAliasMetadata' :: BotAliasMetadata -> Maybe Text
botVersion} -> Maybe Text
botVersion) (\s :: BotAliasMetadata
s@BotAliasMetadata' {} Maybe Text
a -> BotAliasMetadata
s {$sel:botVersion:BotAliasMetadata' :: Maybe Text
botVersion = Maybe Text
a} :: BotAliasMetadata)
botAliasMetadata_botName :: Lens.Lens' BotAliasMetadata (Prelude.Maybe Prelude.Text)
botAliasMetadata_botName :: (Maybe Text -> f (Maybe Text))
-> BotAliasMetadata -> f BotAliasMetadata
botAliasMetadata_botName = (BotAliasMetadata -> Maybe Text)
-> (BotAliasMetadata -> Maybe Text -> BotAliasMetadata)
-> Lens BotAliasMetadata BotAliasMetadata (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\BotAliasMetadata' {Maybe Text
botName :: Maybe Text
$sel:botName:BotAliasMetadata' :: BotAliasMetadata -> Maybe Text
botName} -> Maybe Text
botName) (\s :: BotAliasMetadata
s@BotAliasMetadata' {} Maybe Text
a -> BotAliasMetadata
s {$sel:botName:BotAliasMetadata' :: Maybe Text
botName = Maybe Text
a} :: BotAliasMetadata)
botAliasMetadata_createdDate :: Lens.Lens' BotAliasMetadata (Prelude.Maybe Prelude.UTCTime)
botAliasMetadata_createdDate :: (Maybe UTCTime -> f (Maybe UTCTime))
-> BotAliasMetadata -> f BotAliasMetadata
botAliasMetadata_createdDate = (BotAliasMetadata -> Maybe POSIX)
-> (BotAliasMetadata -> Maybe POSIX -> BotAliasMetadata)
-> Lens
BotAliasMetadata BotAliasMetadata (Maybe POSIX) (Maybe POSIX)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\BotAliasMetadata' {Maybe POSIX
createdDate :: Maybe POSIX
$sel:createdDate:BotAliasMetadata' :: BotAliasMetadata -> Maybe POSIX
createdDate} -> Maybe POSIX
createdDate) (\s :: BotAliasMetadata
s@BotAliasMetadata' {} Maybe POSIX
a -> BotAliasMetadata
s {$sel:createdDate:BotAliasMetadata' :: Maybe POSIX
createdDate = Maybe POSIX
a} :: BotAliasMetadata) ((Maybe POSIX -> f (Maybe POSIX))
-> BotAliasMetadata -> f BotAliasMetadata)
-> ((Maybe UTCTime -> f (Maybe UTCTime))
-> Maybe POSIX -> f (Maybe POSIX))
-> (Maybe UTCTime -> f (Maybe UTCTime))
-> BotAliasMetadata
-> f BotAliasMetadata
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
botAliasMetadata_name :: Lens.Lens' BotAliasMetadata (Prelude.Maybe Prelude.Text)
botAliasMetadata_name :: (Maybe Text -> f (Maybe Text))
-> BotAliasMetadata -> f BotAliasMetadata
botAliasMetadata_name = (BotAliasMetadata -> Maybe Text)
-> (BotAliasMetadata -> Maybe Text -> BotAliasMetadata)
-> Lens BotAliasMetadata BotAliasMetadata (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\BotAliasMetadata' {Maybe Text
name :: Maybe Text
$sel:name:BotAliasMetadata' :: BotAliasMetadata -> Maybe Text
name} -> Maybe Text
name) (\s :: BotAliasMetadata
s@BotAliasMetadata' {} Maybe Text
a -> BotAliasMetadata
s {$sel:name:BotAliasMetadata' :: Maybe Text
name = Maybe Text
a} :: BotAliasMetadata)
botAliasMetadata_conversationLogs :: Lens.Lens' BotAliasMetadata (Prelude.Maybe ConversationLogsResponse)
botAliasMetadata_conversationLogs :: (Maybe ConversationLogsResponse
-> f (Maybe ConversationLogsResponse))
-> BotAliasMetadata -> f BotAliasMetadata
botAliasMetadata_conversationLogs = (BotAliasMetadata -> Maybe ConversationLogsResponse)
-> (BotAliasMetadata
-> Maybe ConversationLogsResponse -> BotAliasMetadata)
-> Lens
BotAliasMetadata
BotAliasMetadata
(Maybe ConversationLogsResponse)
(Maybe ConversationLogsResponse)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\BotAliasMetadata' {Maybe ConversationLogsResponse
conversationLogs :: Maybe ConversationLogsResponse
$sel:conversationLogs:BotAliasMetadata' :: BotAliasMetadata -> Maybe ConversationLogsResponse
conversationLogs} -> Maybe ConversationLogsResponse
conversationLogs) (\s :: BotAliasMetadata
s@BotAliasMetadata' {} Maybe ConversationLogsResponse
a -> BotAliasMetadata
s {$sel:conversationLogs:BotAliasMetadata' :: Maybe ConversationLogsResponse
conversationLogs = Maybe ConversationLogsResponse
a} :: BotAliasMetadata)
botAliasMetadata_lastUpdatedDate :: Lens.Lens' BotAliasMetadata (Prelude.Maybe Prelude.UTCTime)
botAliasMetadata_lastUpdatedDate :: (Maybe UTCTime -> f (Maybe UTCTime))
-> BotAliasMetadata -> f BotAliasMetadata
botAliasMetadata_lastUpdatedDate = (BotAliasMetadata -> Maybe POSIX)
-> (BotAliasMetadata -> Maybe POSIX -> BotAliasMetadata)
-> Lens
BotAliasMetadata BotAliasMetadata (Maybe POSIX) (Maybe POSIX)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\BotAliasMetadata' {Maybe POSIX
lastUpdatedDate :: Maybe POSIX
$sel:lastUpdatedDate:BotAliasMetadata' :: BotAliasMetadata -> Maybe POSIX
lastUpdatedDate} -> Maybe POSIX
lastUpdatedDate) (\s :: BotAliasMetadata
s@BotAliasMetadata' {} Maybe POSIX
a -> BotAliasMetadata
s {$sel:lastUpdatedDate:BotAliasMetadata' :: Maybe POSIX
lastUpdatedDate = Maybe POSIX
a} :: BotAliasMetadata) ((Maybe POSIX -> f (Maybe POSIX))
-> BotAliasMetadata -> f BotAliasMetadata)
-> ((Maybe UTCTime -> f (Maybe UTCTime))
-> Maybe POSIX -> f (Maybe POSIX))
-> (Maybe UTCTime -> f (Maybe UTCTime))
-> BotAliasMetadata
-> f BotAliasMetadata
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
botAliasMetadata_description :: Lens.Lens' BotAliasMetadata (Prelude.Maybe Prelude.Text)
botAliasMetadata_description :: (Maybe Text -> f (Maybe Text))
-> BotAliasMetadata -> f BotAliasMetadata
botAliasMetadata_description = (BotAliasMetadata -> Maybe Text)
-> (BotAliasMetadata -> Maybe Text -> BotAliasMetadata)
-> Lens BotAliasMetadata BotAliasMetadata (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\BotAliasMetadata' {Maybe Text
description :: Maybe Text
$sel:description:BotAliasMetadata' :: BotAliasMetadata -> Maybe Text
description} -> Maybe Text
description) (\s :: BotAliasMetadata
s@BotAliasMetadata' {} Maybe Text
a -> BotAliasMetadata
s {$sel:description:BotAliasMetadata' :: Maybe Text
description = Maybe Text
a} :: BotAliasMetadata)
instance Core.FromJSON BotAliasMetadata where
parseJSON :: Value -> Parser BotAliasMetadata
parseJSON =
String
-> (Object -> Parser BotAliasMetadata)
-> Value
-> Parser BotAliasMetadata
forall a. String -> (Object -> Parser a) -> Value -> Parser a
Core.withObject
String
"BotAliasMetadata"
( \Object
x ->
Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe POSIX
-> Maybe Text
-> Maybe ConversationLogsResponse
-> Maybe POSIX
-> Maybe Text
-> BotAliasMetadata
BotAliasMetadata'
(Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe POSIX
-> Maybe Text
-> Maybe ConversationLogsResponse
-> Maybe POSIX
-> Maybe Text
-> BotAliasMetadata)
-> Parser (Maybe Text)
-> Parser
(Maybe Text
-> Maybe Text
-> Maybe POSIX
-> Maybe Text
-> Maybe ConversationLogsResponse
-> Maybe POSIX
-> Maybe Text
-> BotAliasMetadata)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Object
x Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"checksum")
Parser
(Maybe Text
-> Maybe Text
-> Maybe POSIX
-> Maybe Text
-> Maybe ConversationLogsResponse
-> Maybe POSIX
-> Maybe Text
-> BotAliasMetadata)
-> Parser (Maybe Text)
-> Parser
(Maybe Text
-> Maybe POSIX
-> Maybe Text
-> Maybe ConversationLogsResponse
-> Maybe POSIX
-> Maybe Text
-> BotAliasMetadata)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"botVersion")
Parser
(Maybe Text
-> Maybe POSIX
-> Maybe Text
-> Maybe ConversationLogsResponse
-> Maybe POSIX
-> Maybe Text
-> BotAliasMetadata)
-> Parser (Maybe Text)
-> Parser
(Maybe POSIX
-> Maybe Text
-> Maybe ConversationLogsResponse
-> Maybe POSIX
-> Maybe Text
-> BotAliasMetadata)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"botName")
Parser
(Maybe POSIX
-> Maybe Text
-> Maybe ConversationLogsResponse
-> Maybe POSIX
-> Maybe Text
-> BotAliasMetadata)
-> Parser (Maybe POSIX)
-> Parser
(Maybe Text
-> Maybe ConversationLogsResponse
-> Maybe POSIX
-> Maybe Text
-> BotAliasMetadata)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe POSIX)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"createdDate")
Parser
(Maybe Text
-> Maybe ConversationLogsResponse
-> Maybe POSIX
-> Maybe Text
-> BotAliasMetadata)
-> Parser (Maybe Text)
-> Parser
(Maybe ConversationLogsResponse
-> Maybe POSIX -> Maybe Text -> BotAliasMetadata)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"name")
Parser
(Maybe ConversationLogsResponse
-> Maybe POSIX -> Maybe Text -> BotAliasMetadata)
-> Parser (Maybe ConversationLogsResponse)
-> Parser (Maybe POSIX -> Maybe Text -> BotAliasMetadata)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe ConversationLogsResponse)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"conversationLogs")
Parser (Maybe POSIX -> Maybe Text -> BotAliasMetadata)
-> Parser (Maybe POSIX) -> Parser (Maybe Text -> BotAliasMetadata)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe POSIX)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"lastUpdatedDate")
Parser (Maybe Text -> BotAliasMetadata)
-> Parser (Maybe Text) -> Parser BotAliasMetadata
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"description")
)
instance Prelude.Hashable BotAliasMetadata
instance Prelude.NFData BotAliasMetadata