{-# 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.WorkMail.Types.AccessControlRule where
import qualified Amazonka.Core as Core
import qualified Amazonka.Lens as Lens
import qualified Amazonka.Prelude as Prelude
import Amazonka.WorkMail.Types.AccessControlRuleEffect
data AccessControlRule = AccessControlRule'
{
AccessControlRule -> Maybe AccessControlRuleEffect
effect :: Prelude.Maybe AccessControlRuleEffect,
AccessControlRule -> Maybe [Text]
userIds :: Prelude.Maybe [Prelude.Text],
AccessControlRule -> Maybe [Text]
actions :: Prelude.Maybe [Prelude.Text],
AccessControlRule -> Maybe POSIX
dateCreated :: Prelude.Maybe Core.POSIX,
AccessControlRule -> Maybe Text
name :: Prelude.Maybe Prelude.Text,
AccessControlRule -> Maybe [Text]
notUserIds :: Prelude.Maybe [Prelude.Text],
AccessControlRule -> Maybe POSIX
dateModified :: Prelude.Maybe Core.POSIX,
AccessControlRule -> Maybe [Text]
ipRanges :: Prelude.Maybe [Prelude.Text],
AccessControlRule -> Maybe [Text]
notIpRanges :: Prelude.Maybe [Prelude.Text],
AccessControlRule -> Maybe [Text]
notActions :: Prelude.Maybe [Prelude.Text],
AccessControlRule -> Maybe Text
description :: Prelude.Maybe Prelude.Text
}
deriving (AccessControlRule -> AccessControlRule -> Bool
(AccessControlRule -> AccessControlRule -> Bool)
-> (AccessControlRule -> AccessControlRule -> Bool)
-> Eq AccessControlRule
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: AccessControlRule -> AccessControlRule -> Bool
$c/= :: AccessControlRule -> AccessControlRule -> Bool
== :: AccessControlRule -> AccessControlRule -> Bool
$c== :: AccessControlRule -> AccessControlRule -> Bool
Prelude.Eq, ReadPrec [AccessControlRule]
ReadPrec AccessControlRule
Int -> ReadS AccessControlRule
ReadS [AccessControlRule]
(Int -> ReadS AccessControlRule)
-> ReadS [AccessControlRule]
-> ReadPrec AccessControlRule
-> ReadPrec [AccessControlRule]
-> Read AccessControlRule
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [AccessControlRule]
$creadListPrec :: ReadPrec [AccessControlRule]
readPrec :: ReadPrec AccessControlRule
$creadPrec :: ReadPrec AccessControlRule
readList :: ReadS [AccessControlRule]
$creadList :: ReadS [AccessControlRule]
readsPrec :: Int -> ReadS AccessControlRule
$creadsPrec :: Int -> ReadS AccessControlRule
Prelude.Read, Int -> AccessControlRule -> ShowS
[AccessControlRule] -> ShowS
AccessControlRule -> String
(Int -> AccessControlRule -> ShowS)
-> (AccessControlRule -> String)
-> ([AccessControlRule] -> ShowS)
-> Show AccessControlRule
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [AccessControlRule] -> ShowS
$cshowList :: [AccessControlRule] -> ShowS
show :: AccessControlRule -> String
$cshow :: AccessControlRule -> String
showsPrec :: Int -> AccessControlRule -> ShowS
$cshowsPrec :: Int -> AccessControlRule -> ShowS
Prelude.Show, (forall x. AccessControlRule -> Rep AccessControlRule x)
-> (forall x. Rep AccessControlRule x -> AccessControlRule)
-> Generic AccessControlRule
forall x. Rep AccessControlRule x -> AccessControlRule
forall x. AccessControlRule -> Rep AccessControlRule x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep AccessControlRule x -> AccessControlRule
$cfrom :: forall x. AccessControlRule -> Rep AccessControlRule x
Prelude.Generic)
newAccessControlRule ::
AccessControlRule
newAccessControlRule :: AccessControlRule
newAccessControlRule =
AccessControlRule' :: Maybe AccessControlRuleEffect
-> Maybe [Text]
-> Maybe [Text]
-> Maybe POSIX
-> Maybe Text
-> Maybe [Text]
-> Maybe POSIX
-> Maybe [Text]
-> Maybe [Text]
-> Maybe [Text]
-> Maybe Text
-> AccessControlRule
AccessControlRule'
{ $sel:effect:AccessControlRule' :: Maybe AccessControlRuleEffect
effect = Maybe AccessControlRuleEffect
forall a. Maybe a
Prelude.Nothing,
$sel:userIds:AccessControlRule' :: Maybe [Text]
userIds = Maybe [Text]
forall a. Maybe a
Prelude.Nothing,
$sel:actions:AccessControlRule' :: Maybe [Text]
actions = Maybe [Text]
forall a. Maybe a
Prelude.Nothing,
$sel:dateCreated:AccessControlRule' :: Maybe POSIX
dateCreated = Maybe POSIX
forall a. Maybe a
Prelude.Nothing,
$sel:name:AccessControlRule' :: Maybe Text
name = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:notUserIds:AccessControlRule' :: Maybe [Text]
notUserIds = Maybe [Text]
forall a. Maybe a
Prelude.Nothing,
$sel:dateModified:AccessControlRule' :: Maybe POSIX
dateModified = Maybe POSIX
forall a. Maybe a
Prelude.Nothing,
$sel:ipRanges:AccessControlRule' :: Maybe [Text]
ipRanges = Maybe [Text]
forall a. Maybe a
Prelude.Nothing,
$sel:notIpRanges:AccessControlRule' :: Maybe [Text]
notIpRanges = Maybe [Text]
forall a. Maybe a
Prelude.Nothing,
$sel:notActions:AccessControlRule' :: Maybe [Text]
notActions = Maybe [Text]
forall a. Maybe a
Prelude.Nothing,
$sel:description:AccessControlRule' :: Maybe Text
description = Maybe Text
forall a. Maybe a
Prelude.Nothing
}
accessControlRule_effect :: Lens.Lens' AccessControlRule (Prelude.Maybe AccessControlRuleEffect)
accessControlRule_effect :: (Maybe AccessControlRuleEffect
-> f (Maybe AccessControlRuleEffect))
-> AccessControlRule -> f AccessControlRule
accessControlRule_effect = (AccessControlRule -> Maybe AccessControlRuleEffect)
-> (AccessControlRule
-> Maybe AccessControlRuleEffect -> AccessControlRule)
-> Lens
AccessControlRule
AccessControlRule
(Maybe AccessControlRuleEffect)
(Maybe AccessControlRuleEffect)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AccessControlRule' {Maybe AccessControlRuleEffect
effect :: Maybe AccessControlRuleEffect
$sel:effect:AccessControlRule' :: AccessControlRule -> Maybe AccessControlRuleEffect
effect} -> Maybe AccessControlRuleEffect
effect) (\s :: AccessControlRule
s@AccessControlRule' {} Maybe AccessControlRuleEffect
a -> AccessControlRule
s {$sel:effect:AccessControlRule' :: Maybe AccessControlRuleEffect
effect = Maybe AccessControlRuleEffect
a} :: AccessControlRule)
accessControlRule_userIds :: Lens.Lens' AccessControlRule (Prelude.Maybe [Prelude.Text])
accessControlRule_userIds :: (Maybe [Text] -> f (Maybe [Text]))
-> AccessControlRule -> f AccessControlRule
accessControlRule_userIds = (AccessControlRule -> Maybe [Text])
-> (AccessControlRule -> Maybe [Text] -> AccessControlRule)
-> Lens
AccessControlRule AccessControlRule (Maybe [Text]) (Maybe [Text])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AccessControlRule' {Maybe [Text]
userIds :: Maybe [Text]
$sel:userIds:AccessControlRule' :: AccessControlRule -> Maybe [Text]
userIds} -> Maybe [Text]
userIds) (\s :: AccessControlRule
s@AccessControlRule' {} Maybe [Text]
a -> AccessControlRule
s {$sel:userIds:AccessControlRule' :: Maybe [Text]
userIds = Maybe [Text]
a} :: AccessControlRule) ((Maybe [Text] -> f (Maybe [Text]))
-> AccessControlRule -> f AccessControlRule)
-> ((Maybe [Text] -> f (Maybe [Text]))
-> Maybe [Text] -> f (Maybe [Text]))
-> (Maybe [Text] -> f (Maybe [Text]))
-> AccessControlRule
-> f AccessControlRule
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso [Text] [Text] [Text] [Text]
-> Iso (Maybe [Text]) (Maybe [Text]) (Maybe [Text]) (Maybe [Text])
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 [Text] [Text] [Text] [Text]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced
accessControlRule_actions :: Lens.Lens' AccessControlRule (Prelude.Maybe [Prelude.Text])
accessControlRule_actions :: (Maybe [Text] -> f (Maybe [Text]))
-> AccessControlRule -> f AccessControlRule
accessControlRule_actions = (AccessControlRule -> Maybe [Text])
-> (AccessControlRule -> Maybe [Text] -> AccessControlRule)
-> Lens
AccessControlRule AccessControlRule (Maybe [Text]) (Maybe [Text])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AccessControlRule' {Maybe [Text]
actions :: Maybe [Text]
$sel:actions:AccessControlRule' :: AccessControlRule -> Maybe [Text]
actions} -> Maybe [Text]
actions) (\s :: AccessControlRule
s@AccessControlRule' {} Maybe [Text]
a -> AccessControlRule
s {$sel:actions:AccessControlRule' :: Maybe [Text]
actions = Maybe [Text]
a} :: AccessControlRule) ((Maybe [Text] -> f (Maybe [Text]))
-> AccessControlRule -> f AccessControlRule)
-> ((Maybe [Text] -> f (Maybe [Text]))
-> Maybe [Text] -> f (Maybe [Text]))
-> (Maybe [Text] -> f (Maybe [Text]))
-> AccessControlRule
-> f AccessControlRule
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso [Text] [Text] [Text] [Text]
-> Iso (Maybe [Text]) (Maybe [Text]) (Maybe [Text]) (Maybe [Text])
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 [Text] [Text] [Text] [Text]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced
accessControlRule_dateCreated :: Lens.Lens' AccessControlRule (Prelude.Maybe Prelude.UTCTime)
accessControlRule_dateCreated :: (Maybe UTCTime -> f (Maybe UTCTime))
-> AccessControlRule -> f AccessControlRule
accessControlRule_dateCreated = (AccessControlRule -> Maybe POSIX)
-> (AccessControlRule -> Maybe POSIX -> AccessControlRule)
-> Lens
AccessControlRule AccessControlRule (Maybe POSIX) (Maybe POSIX)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AccessControlRule' {Maybe POSIX
dateCreated :: Maybe POSIX
$sel:dateCreated:AccessControlRule' :: AccessControlRule -> Maybe POSIX
dateCreated} -> Maybe POSIX
dateCreated) (\s :: AccessControlRule
s@AccessControlRule' {} Maybe POSIX
a -> AccessControlRule
s {$sel:dateCreated:AccessControlRule' :: Maybe POSIX
dateCreated = Maybe POSIX
a} :: AccessControlRule) ((Maybe POSIX -> f (Maybe POSIX))
-> AccessControlRule -> f AccessControlRule)
-> ((Maybe UTCTime -> f (Maybe UTCTime))
-> Maybe POSIX -> f (Maybe POSIX))
-> (Maybe UTCTime -> f (Maybe UTCTime))
-> AccessControlRule
-> f AccessControlRule
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
accessControlRule_name :: Lens.Lens' AccessControlRule (Prelude.Maybe Prelude.Text)
accessControlRule_name :: (Maybe Text -> f (Maybe Text))
-> AccessControlRule -> f AccessControlRule
accessControlRule_name = (AccessControlRule -> Maybe Text)
-> (AccessControlRule -> Maybe Text -> AccessControlRule)
-> Lens
AccessControlRule AccessControlRule (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AccessControlRule' {Maybe Text
name :: Maybe Text
$sel:name:AccessControlRule' :: AccessControlRule -> Maybe Text
name} -> Maybe Text
name) (\s :: AccessControlRule
s@AccessControlRule' {} Maybe Text
a -> AccessControlRule
s {$sel:name:AccessControlRule' :: Maybe Text
name = Maybe Text
a} :: AccessControlRule)
accessControlRule_notUserIds :: Lens.Lens' AccessControlRule (Prelude.Maybe [Prelude.Text])
accessControlRule_notUserIds :: (Maybe [Text] -> f (Maybe [Text]))
-> AccessControlRule -> f AccessControlRule
accessControlRule_notUserIds = (AccessControlRule -> Maybe [Text])
-> (AccessControlRule -> Maybe [Text] -> AccessControlRule)
-> Lens
AccessControlRule AccessControlRule (Maybe [Text]) (Maybe [Text])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AccessControlRule' {Maybe [Text]
notUserIds :: Maybe [Text]
$sel:notUserIds:AccessControlRule' :: AccessControlRule -> Maybe [Text]
notUserIds} -> Maybe [Text]
notUserIds) (\s :: AccessControlRule
s@AccessControlRule' {} Maybe [Text]
a -> AccessControlRule
s {$sel:notUserIds:AccessControlRule' :: Maybe [Text]
notUserIds = Maybe [Text]
a} :: AccessControlRule) ((Maybe [Text] -> f (Maybe [Text]))
-> AccessControlRule -> f AccessControlRule)
-> ((Maybe [Text] -> f (Maybe [Text]))
-> Maybe [Text] -> f (Maybe [Text]))
-> (Maybe [Text] -> f (Maybe [Text]))
-> AccessControlRule
-> f AccessControlRule
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso [Text] [Text] [Text] [Text]
-> Iso (Maybe [Text]) (Maybe [Text]) (Maybe [Text]) (Maybe [Text])
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 [Text] [Text] [Text] [Text]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced
accessControlRule_dateModified :: Lens.Lens' AccessControlRule (Prelude.Maybe Prelude.UTCTime)
accessControlRule_dateModified :: (Maybe UTCTime -> f (Maybe UTCTime))
-> AccessControlRule -> f AccessControlRule
accessControlRule_dateModified = (AccessControlRule -> Maybe POSIX)
-> (AccessControlRule -> Maybe POSIX -> AccessControlRule)
-> Lens
AccessControlRule AccessControlRule (Maybe POSIX) (Maybe POSIX)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AccessControlRule' {Maybe POSIX
dateModified :: Maybe POSIX
$sel:dateModified:AccessControlRule' :: AccessControlRule -> Maybe POSIX
dateModified} -> Maybe POSIX
dateModified) (\s :: AccessControlRule
s@AccessControlRule' {} Maybe POSIX
a -> AccessControlRule
s {$sel:dateModified:AccessControlRule' :: Maybe POSIX
dateModified = Maybe POSIX
a} :: AccessControlRule) ((Maybe POSIX -> f (Maybe POSIX))
-> AccessControlRule -> f AccessControlRule)
-> ((Maybe UTCTime -> f (Maybe UTCTime))
-> Maybe POSIX -> f (Maybe POSIX))
-> (Maybe UTCTime -> f (Maybe UTCTime))
-> AccessControlRule
-> f AccessControlRule
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
accessControlRule_ipRanges :: Lens.Lens' AccessControlRule (Prelude.Maybe [Prelude.Text])
accessControlRule_ipRanges :: (Maybe [Text] -> f (Maybe [Text]))
-> AccessControlRule -> f AccessControlRule
accessControlRule_ipRanges = (AccessControlRule -> Maybe [Text])
-> (AccessControlRule -> Maybe [Text] -> AccessControlRule)
-> Lens
AccessControlRule AccessControlRule (Maybe [Text]) (Maybe [Text])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AccessControlRule' {Maybe [Text]
ipRanges :: Maybe [Text]
$sel:ipRanges:AccessControlRule' :: AccessControlRule -> Maybe [Text]
ipRanges} -> Maybe [Text]
ipRanges) (\s :: AccessControlRule
s@AccessControlRule' {} Maybe [Text]
a -> AccessControlRule
s {$sel:ipRanges:AccessControlRule' :: Maybe [Text]
ipRanges = Maybe [Text]
a} :: AccessControlRule) ((Maybe [Text] -> f (Maybe [Text]))
-> AccessControlRule -> f AccessControlRule)
-> ((Maybe [Text] -> f (Maybe [Text]))
-> Maybe [Text] -> f (Maybe [Text]))
-> (Maybe [Text] -> f (Maybe [Text]))
-> AccessControlRule
-> f AccessControlRule
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso [Text] [Text] [Text] [Text]
-> Iso (Maybe [Text]) (Maybe [Text]) (Maybe [Text]) (Maybe [Text])
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 [Text] [Text] [Text] [Text]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced
accessControlRule_notIpRanges :: Lens.Lens' AccessControlRule (Prelude.Maybe [Prelude.Text])
accessControlRule_notIpRanges :: (Maybe [Text] -> f (Maybe [Text]))
-> AccessControlRule -> f AccessControlRule
accessControlRule_notIpRanges = (AccessControlRule -> Maybe [Text])
-> (AccessControlRule -> Maybe [Text] -> AccessControlRule)
-> Lens
AccessControlRule AccessControlRule (Maybe [Text]) (Maybe [Text])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AccessControlRule' {Maybe [Text]
notIpRanges :: Maybe [Text]
$sel:notIpRanges:AccessControlRule' :: AccessControlRule -> Maybe [Text]
notIpRanges} -> Maybe [Text]
notIpRanges) (\s :: AccessControlRule
s@AccessControlRule' {} Maybe [Text]
a -> AccessControlRule
s {$sel:notIpRanges:AccessControlRule' :: Maybe [Text]
notIpRanges = Maybe [Text]
a} :: AccessControlRule) ((Maybe [Text] -> f (Maybe [Text]))
-> AccessControlRule -> f AccessControlRule)
-> ((Maybe [Text] -> f (Maybe [Text]))
-> Maybe [Text] -> f (Maybe [Text]))
-> (Maybe [Text] -> f (Maybe [Text]))
-> AccessControlRule
-> f AccessControlRule
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso [Text] [Text] [Text] [Text]
-> Iso (Maybe [Text]) (Maybe [Text]) (Maybe [Text]) (Maybe [Text])
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 [Text] [Text] [Text] [Text]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced
accessControlRule_notActions :: Lens.Lens' AccessControlRule (Prelude.Maybe [Prelude.Text])
accessControlRule_notActions :: (Maybe [Text] -> f (Maybe [Text]))
-> AccessControlRule -> f AccessControlRule
accessControlRule_notActions = (AccessControlRule -> Maybe [Text])
-> (AccessControlRule -> Maybe [Text] -> AccessControlRule)
-> Lens
AccessControlRule AccessControlRule (Maybe [Text]) (Maybe [Text])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AccessControlRule' {Maybe [Text]
notActions :: Maybe [Text]
$sel:notActions:AccessControlRule' :: AccessControlRule -> Maybe [Text]
notActions} -> Maybe [Text]
notActions) (\s :: AccessControlRule
s@AccessControlRule' {} Maybe [Text]
a -> AccessControlRule
s {$sel:notActions:AccessControlRule' :: Maybe [Text]
notActions = Maybe [Text]
a} :: AccessControlRule) ((Maybe [Text] -> f (Maybe [Text]))
-> AccessControlRule -> f AccessControlRule)
-> ((Maybe [Text] -> f (Maybe [Text]))
-> Maybe [Text] -> f (Maybe [Text]))
-> (Maybe [Text] -> f (Maybe [Text]))
-> AccessControlRule
-> f AccessControlRule
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso [Text] [Text] [Text] [Text]
-> Iso (Maybe [Text]) (Maybe [Text]) (Maybe [Text]) (Maybe [Text])
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 [Text] [Text] [Text] [Text]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced
accessControlRule_description :: Lens.Lens' AccessControlRule (Prelude.Maybe Prelude.Text)
accessControlRule_description :: (Maybe Text -> f (Maybe Text))
-> AccessControlRule -> f AccessControlRule
accessControlRule_description = (AccessControlRule -> Maybe Text)
-> (AccessControlRule -> Maybe Text -> AccessControlRule)
-> Lens
AccessControlRule AccessControlRule (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AccessControlRule' {Maybe Text
description :: Maybe Text
$sel:description:AccessControlRule' :: AccessControlRule -> Maybe Text
description} -> Maybe Text
description) (\s :: AccessControlRule
s@AccessControlRule' {} Maybe Text
a -> AccessControlRule
s {$sel:description:AccessControlRule' :: Maybe Text
description = Maybe Text
a} :: AccessControlRule)
instance Core.FromJSON AccessControlRule where
parseJSON :: Value -> Parser AccessControlRule
parseJSON =
String
-> (Object -> Parser AccessControlRule)
-> Value
-> Parser AccessControlRule
forall a. String -> (Object -> Parser a) -> Value -> Parser a
Core.withObject
String
"AccessControlRule"
( \Object
x ->
Maybe AccessControlRuleEffect
-> Maybe [Text]
-> Maybe [Text]
-> Maybe POSIX
-> Maybe Text
-> Maybe [Text]
-> Maybe POSIX
-> Maybe [Text]
-> Maybe [Text]
-> Maybe [Text]
-> Maybe Text
-> AccessControlRule
AccessControlRule'
(Maybe AccessControlRuleEffect
-> Maybe [Text]
-> Maybe [Text]
-> Maybe POSIX
-> Maybe Text
-> Maybe [Text]
-> Maybe POSIX
-> Maybe [Text]
-> Maybe [Text]
-> Maybe [Text]
-> Maybe Text
-> AccessControlRule)
-> Parser (Maybe AccessControlRuleEffect)
-> Parser
(Maybe [Text]
-> Maybe [Text]
-> Maybe POSIX
-> Maybe Text
-> Maybe [Text]
-> Maybe POSIX
-> Maybe [Text]
-> Maybe [Text]
-> Maybe [Text]
-> Maybe Text
-> AccessControlRule)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Object
x Object -> Text -> Parser (Maybe AccessControlRuleEffect)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"Effect")
Parser
(Maybe [Text]
-> Maybe [Text]
-> Maybe POSIX
-> Maybe Text
-> Maybe [Text]
-> Maybe POSIX
-> Maybe [Text]
-> Maybe [Text]
-> Maybe [Text]
-> Maybe Text
-> AccessControlRule)
-> Parser (Maybe [Text])
-> Parser
(Maybe [Text]
-> Maybe POSIX
-> Maybe Text
-> Maybe [Text]
-> Maybe POSIX
-> Maybe [Text]
-> Maybe [Text]
-> Maybe [Text]
-> Maybe Text
-> AccessControlRule)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe (Maybe [Text]))
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"UserIds" Parser (Maybe (Maybe [Text]))
-> Maybe [Text] -> Parser (Maybe [Text])
forall a. Parser (Maybe a) -> a -> Parser a
Core..!= Maybe [Text]
forall a. Monoid a => a
Prelude.mempty)
Parser
(Maybe [Text]
-> Maybe POSIX
-> Maybe Text
-> Maybe [Text]
-> Maybe POSIX
-> Maybe [Text]
-> Maybe [Text]
-> Maybe [Text]
-> Maybe Text
-> AccessControlRule)
-> Parser (Maybe [Text])
-> Parser
(Maybe POSIX
-> Maybe Text
-> Maybe [Text]
-> Maybe POSIX
-> Maybe [Text]
-> Maybe [Text]
-> Maybe [Text]
-> Maybe Text
-> AccessControlRule)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe (Maybe [Text]))
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"Actions" Parser (Maybe (Maybe [Text]))
-> Maybe [Text] -> Parser (Maybe [Text])
forall a. Parser (Maybe a) -> a -> Parser a
Core..!= Maybe [Text]
forall a. Monoid a => a
Prelude.mempty)
Parser
(Maybe POSIX
-> Maybe Text
-> Maybe [Text]
-> Maybe POSIX
-> Maybe [Text]
-> Maybe [Text]
-> Maybe [Text]
-> Maybe Text
-> AccessControlRule)
-> Parser (Maybe POSIX)
-> Parser
(Maybe Text
-> Maybe [Text]
-> Maybe POSIX
-> Maybe [Text]
-> Maybe [Text]
-> Maybe [Text]
-> Maybe Text
-> AccessControlRule)
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
"DateCreated")
Parser
(Maybe Text
-> Maybe [Text]
-> Maybe POSIX
-> Maybe [Text]
-> Maybe [Text]
-> Maybe [Text]
-> Maybe Text
-> AccessControlRule)
-> Parser (Maybe Text)
-> Parser
(Maybe [Text]
-> Maybe POSIX
-> Maybe [Text]
-> Maybe [Text]
-> Maybe [Text]
-> Maybe Text
-> AccessControlRule)
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 [Text]
-> Maybe POSIX
-> Maybe [Text]
-> Maybe [Text]
-> Maybe [Text]
-> Maybe Text
-> AccessControlRule)
-> Parser (Maybe [Text])
-> Parser
(Maybe POSIX
-> Maybe [Text]
-> Maybe [Text]
-> Maybe [Text]
-> Maybe Text
-> AccessControlRule)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe (Maybe [Text]))
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"NotUserIds" Parser (Maybe (Maybe [Text]))
-> Maybe [Text] -> Parser (Maybe [Text])
forall a. Parser (Maybe a) -> a -> Parser a
Core..!= Maybe [Text]
forall a. Monoid a => a
Prelude.mempty)
Parser
(Maybe POSIX
-> Maybe [Text]
-> Maybe [Text]
-> Maybe [Text]
-> Maybe Text
-> AccessControlRule)
-> Parser (Maybe POSIX)
-> Parser
(Maybe [Text]
-> Maybe [Text] -> Maybe [Text] -> Maybe Text -> AccessControlRule)
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
"DateModified")
Parser
(Maybe [Text]
-> Maybe [Text] -> Maybe [Text] -> Maybe Text -> AccessControlRule)
-> Parser (Maybe [Text])
-> Parser
(Maybe [Text] -> Maybe [Text] -> Maybe Text -> AccessControlRule)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe (Maybe [Text]))
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"IpRanges" Parser (Maybe (Maybe [Text]))
-> Maybe [Text] -> Parser (Maybe [Text])
forall a. Parser (Maybe a) -> a -> Parser a
Core..!= Maybe [Text]
forall a. Monoid a => a
Prelude.mempty)
Parser
(Maybe [Text] -> Maybe [Text] -> Maybe Text -> AccessControlRule)
-> Parser (Maybe [Text])
-> Parser (Maybe [Text] -> Maybe Text -> AccessControlRule)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe (Maybe [Text]))
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"NotIpRanges" Parser (Maybe (Maybe [Text]))
-> Maybe [Text] -> Parser (Maybe [Text])
forall a. Parser (Maybe a) -> a -> Parser a
Core..!= Maybe [Text]
forall a. Monoid a => a
Prelude.mempty)
Parser (Maybe [Text] -> Maybe Text -> AccessControlRule)
-> Parser (Maybe [Text])
-> Parser (Maybe Text -> AccessControlRule)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe (Maybe [Text]))
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"NotActions" Parser (Maybe (Maybe [Text]))
-> Maybe [Text] -> Parser (Maybe [Text])
forall a. Parser (Maybe a) -> a -> Parser a
Core..!= Maybe [Text]
forall a. Monoid a => a
Prelude.mempty)
Parser (Maybe Text -> AccessControlRule)
-> Parser (Maybe Text) -> Parser AccessControlRule
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 AccessControlRule
instance Prelude.NFData AccessControlRule