{-# 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.AlexaBusiness.Types.MeetingSetting where
import Amazonka.AlexaBusiness.Types.RequirePin
import qualified Amazonka.Core as Core
import qualified Amazonka.Core.Lens.Internal as Lens
import qualified Amazonka.Data as Data
import qualified Amazonka.Prelude as Prelude
data MeetingSetting = MeetingSetting'
{
MeetingSetting -> RequirePin
requirePin :: RequirePin
}
deriving (MeetingSetting -> MeetingSetting -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: MeetingSetting -> MeetingSetting -> Bool
$c/= :: MeetingSetting -> MeetingSetting -> Bool
== :: MeetingSetting -> MeetingSetting -> Bool
$c== :: MeetingSetting -> MeetingSetting -> Bool
Prelude.Eq, ReadPrec [MeetingSetting]
ReadPrec MeetingSetting
Int -> ReadS MeetingSetting
ReadS [MeetingSetting]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [MeetingSetting]
$creadListPrec :: ReadPrec [MeetingSetting]
readPrec :: ReadPrec MeetingSetting
$creadPrec :: ReadPrec MeetingSetting
readList :: ReadS [MeetingSetting]
$creadList :: ReadS [MeetingSetting]
readsPrec :: Int -> ReadS MeetingSetting
$creadsPrec :: Int -> ReadS MeetingSetting
Prelude.Read, Int -> MeetingSetting -> ShowS
[MeetingSetting] -> ShowS
MeetingSetting -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [MeetingSetting] -> ShowS
$cshowList :: [MeetingSetting] -> ShowS
show :: MeetingSetting -> String
$cshow :: MeetingSetting -> String
showsPrec :: Int -> MeetingSetting -> ShowS
$cshowsPrec :: Int -> MeetingSetting -> ShowS
Prelude.Show, forall x. Rep MeetingSetting x -> MeetingSetting
forall x. MeetingSetting -> Rep MeetingSetting x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep MeetingSetting x -> MeetingSetting
$cfrom :: forall x. MeetingSetting -> Rep MeetingSetting x
Prelude.Generic)
newMeetingSetting ::
RequirePin ->
MeetingSetting
newMeetingSetting :: RequirePin -> MeetingSetting
newMeetingSetting RequirePin
pRequirePin_ =
MeetingSetting' {$sel:requirePin:MeetingSetting' :: RequirePin
requirePin = RequirePin
pRequirePin_}
meetingSetting_requirePin :: Lens.Lens' MeetingSetting RequirePin
meetingSetting_requirePin :: Lens' MeetingSetting RequirePin
meetingSetting_requirePin = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\MeetingSetting' {RequirePin
requirePin :: RequirePin
$sel:requirePin:MeetingSetting' :: MeetingSetting -> RequirePin
requirePin} -> RequirePin
requirePin) (\s :: MeetingSetting
s@MeetingSetting' {} RequirePin
a -> MeetingSetting
s {$sel:requirePin:MeetingSetting' :: RequirePin
requirePin = RequirePin
a} :: MeetingSetting)
instance Data.FromJSON MeetingSetting where
parseJSON :: Value -> Parser MeetingSetting
parseJSON =
forall a. String -> (Object -> Parser a) -> Value -> Parser a
Data.withObject
String
"MeetingSetting"
( \Object
x ->
RequirePin -> MeetingSetting
MeetingSetting' forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Object
x forall a. FromJSON a => Object -> Key -> Parser a
Data..: Key
"RequirePin")
)
instance Prelude.Hashable MeetingSetting where
hashWithSalt :: Int -> MeetingSetting -> Int
hashWithSalt Int
_salt MeetingSetting' {RequirePin
requirePin :: RequirePin
$sel:requirePin:MeetingSetting' :: MeetingSetting -> RequirePin
..} =
Int
_salt forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` RequirePin
requirePin
instance Prelude.NFData MeetingSetting where
rnf :: MeetingSetting -> ()
rnf MeetingSetting' {RequirePin
requirePin :: RequirePin
$sel:requirePin:MeetingSetting' :: MeetingSetting -> RequirePin
..} = forall a. NFData a => a -> ()
Prelude.rnf RequirePin
requirePin
instance Data.ToJSON MeetingSetting where
toJSON :: MeetingSetting -> Value
toJSON MeetingSetting' {RequirePin
requirePin :: RequirePin
$sel:requirePin:MeetingSetting' :: MeetingSetting -> RequirePin
..} =
[Pair] -> Value
Data.object
( forall a. [Maybe a] -> [a]
Prelude.catMaybes
[forall a. a -> Maybe a
Prelude.Just (Key
"RequirePin" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..= RequirePin
requirePin)]
)