{-# 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 #-}
module Amazonka.WAFV2.DescribeManagedRuleGroup
(
DescribeManagedRuleGroup (..),
newDescribeManagedRuleGroup,
describeManagedRuleGroup_versionName,
describeManagedRuleGroup_vendorName,
describeManagedRuleGroup_name,
describeManagedRuleGroup_scope,
DescribeManagedRuleGroupResponse (..),
newDescribeManagedRuleGroupResponse,
describeManagedRuleGroupResponse_availableLabels,
describeManagedRuleGroupResponse_capacity,
describeManagedRuleGroupResponse_consumedLabels,
describeManagedRuleGroupResponse_labelNamespace,
describeManagedRuleGroupResponse_rules,
describeManagedRuleGroupResponse_snsTopicArn,
describeManagedRuleGroupResponse_versionName,
describeManagedRuleGroupResponse_httpStatus,
)
where
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
import qualified Amazonka.Request as Request
import qualified Amazonka.Response as Response
import Amazonka.WAFV2.Types
data DescribeManagedRuleGroup = DescribeManagedRuleGroup'
{
DescribeManagedRuleGroup -> Maybe Text
versionName :: Prelude.Maybe Prelude.Text,
DescribeManagedRuleGroup -> Text
vendorName :: Prelude.Text,
DescribeManagedRuleGroup -> Text
name :: Prelude.Text,
DescribeManagedRuleGroup -> Scope
scope :: Scope
}
deriving (DescribeManagedRuleGroup -> DescribeManagedRuleGroup -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: DescribeManagedRuleGroup -> DescribeManagedRuleGroup -> Bool
$c/= :: DescribeManagedRuleGroup -> DescribeManagedRuleGroup -> Bool
== :: DescribeManagedRuleGroup -> DescribeManagedRuleGroup -> Bool
$c== :: DescribeManagedRuleGroup -> DescribeManagedRuleGroup -> Bool
Prelude.Eq, ReadPrec [DescribeManagedRuleGroup]
ReadPrec DescribeManagedRuleGroup
Int -> ReadS DescribeManagedRuleGroup
ReadS [DescribeManagedRuleGroup]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [DescribeManagedRuleGroup]
$creadListPrec :: ReadPrec [DescribeManagedRuleGroup]
readPrec :: ReadPrec DescribeManagedRuleGroup
$creadPrec :: ReadPrec DescribeManagedRuleGroup
readList :: ReadS [DescribeManagedRuleGroup]
$creadList :: ReadS [DescribeManagedRuleGroup]
readsPrec :: Int -> ReadS DescribeManagedRuleGroup
$creadsPrec :: Int -> ReadS DescribeManagedRuleGroup
Prelude.Read, Int -> DescribeManagedRuleGroup -> ShowS
[DescribeManagedRuleGroup] -> ShowS
DescribeManagedRuleGroup -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [DescribeManagedRuleGroup] -> ShowS
$cshowList :: [DescribeManagedRuleGroup] -> ShowS
show :: DescribeManagedRuleGroup -> String
$cshow :: DescribeManagedRuleGroup -> String
showsPrec :: Int -> DescribeManagedRuleGroup -> ShowS
$cshowsPrec :: Int -> DescribeManagedRuleGroup -> ShowS
Prelude.Show, forall x.
Rep DescribeManagedRuleGroup x -> DescribeManagedRuleGroup
forall x.
DescribeManagedRuleGroup -> Rep DescribeManagedRuleGroup x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep DescribeManagedRuleGroup x -> DescribeManagedRuleGroup
$cfrom :: forall x.
DescribeManagedRuleGroup -> Rep DescribeManagedRuleGroup x
Prelude.Generic)
newDescribeManagedRuleGroup ::
Prelude.Text ->
Prelude.Text ->
Scope ->
DescribeManagedRuleGroup
newDescribeManagedRuleGroup :: Text -> Text -> Scope -> DescribeManagedRuleGroup
newDescribeManagedRuleGroup
Text
pVendorName_
Text
pName_
Scope
pScope_ =
DescribeManagedRuleGroup'
{ $sel:versionName:DescribeManagedRuleGroup' :: Maybe Text
versionName =
forall a. Maybe a
Prelude.Nothing,
$sel:vendorName:DescribeManagedRuleGroup' :: Text
vendorName = Text
pVendorName_,
$sel:name:DescribeManagedRuleGroup' :: Text
name = Text
pName_,
$sel:scope:DescribeManagedRuleGroup' :: Scope
scope = Scope
pScope_
}
describeManagedRuleGroup_versionName :: Lens.Lens' DescribeManagedRuleGroup (Prelude.Maybe Prelude.Text)
describeManagedRuleGroup_versionName :: Lens' DescribeManagedRuleGroup (Maybe Text)
describeManagedRuleGroup_versionName = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DescribeManagedRuleGroup' {Maybe Text
versionName :: Maybe Text
$sel:versionName:DescribeManagedRuleGroup' :: DescribeManagedRuleGroup -> Maybe Text
versionName} -> Maybe Text
versionName) (\s :: DescribeManagedRuleGroup
s@DescribeManagedRuleGroup' {} Maybe Text
a -> DescribeManagedRuleGroup
s {$sel:versionName:DescribeManagedRuleGroup' :: Maybe Text
versionName = Maybe Text
a} :: DescribeManagedRuleGroup)
describeManagedRuleGroup_vendorName :: Lens.Lens' DescribeManagedRuleGroup Prelude.Text
describeManagedRuleGroup_vendorName :: Lens' DescribeManagedRuleGroup Text
describeManagedRuleGroup_vendorName = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DescribeManagedRuleGroup' {Text
vendorName :: Text
$sel:vendorName:DescribeManagedRuleGroup' :: DescribeManagedRuleGroup -> Text
vendorName} -> Text
vendorName) (\s :: DescribeManagedRuleGroup
s@DescribeManagedRuleGroup' {} Text
a -> DescribeManagedRuleGroup
s {$sel:vendorName:DescribeManagedRuleGroup' :: Text
vendorName = Text
a} :: DescribeManagedRuleGroup)
describeManagedRuleGroup_name :: Lens.Lens' DescribeManagedRuleGroup Prelude.Text
describeManagedRuleGroup_name :: Lens' DescribeManagedRuleGroup Text
describeManagedRuleGroup_name = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DescribeManagedRuleGroup' {Text
name :: Text
$sel:name:DescribeManagedRuleGroup' :: DescribeManagedRuleGroup -> Text
name} -> Text
name) (\s :: DescribeManagedRuleGroup
s@DescribeManagedRuleGroup' {} Text
a -> DescribeManagedRuleGroup
s {$sel:name:DescribeManagedRuleGroup' :: Text
name = Text
a} :: DescribeManagedRuleGroup)
describeManagedRuleGroup_scope :: Lens.Lens' DescribeManagedRuleGroup Scope
describeManagedRuleGroup_scope :: Lens' DescribeManagedRuleGroup Scope
describeManagedRuleGroup_scope = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DescribeManagedRuleGroup' {Scope
scope :: Scope
$sel:scope:DescribeManagedRuleGroup' :: DescribeManagedRuleGroup -> Scope
scope} -> Scope
scope) (\s :: DescribeManagedRuleGroup
s@DescribeManagedRuleGroup' {} Scope
a -> DescribeManagedRuleGroup
s {$sel:scope:DescribeManagedRuleGroup' :: Scope
scope = Scope
a} :: DescribeManagedRuleGroup)
instance Core.AWSRequest DescribeManagedRuleGroup where
type
AWSResponse DescribeManagedRuleGroup =
DescribeManagedRuleGroupResponse
request :: (Service -> Service)
-> DescribeManagedRuleGroup -> Request DescribeManagedRuleGroup
request Service -> Service
overrides =
forall a. (ToRequest a, ToJSON a) => Service -> a -> Request a
Request.postJSON (Service -> Service
overrides Service
defaultService)
response :: forall (m :: * -> *).
MonadResource m =>
(ByteStringLazy -> IO ByteStringLazy)
-> Service
-> Proxy DescribeManagedRuleGroup
-> ClientResponse ClientBody
-> m (Either
Error (ClientResponse (AWSResponse DescribeManagedRuleGroup)))
response =
forall (m :: * -> *) a.
MonadResource m =>
(Int -> ResponseHeaders -> Object -> Either String (AWSResponse a))
-> (ByteStringLazy -> IO ByteStringLazy)
-> Service
-> Proxy a
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse a)))
Response.receiveJSON
( \Int
s ResponseHeaders
h Object
x ->
Maybe [LabelSummary]
-> Maybe Natural
-> Maybe [LabelSummary]
-> Maybe Text
-> Maybe [RuleSummary]
-> Maybe Text
-> Maybe Text
-> Int
-> DescribeManagedRuleGroupResponse
DescribeManagedRuleGroupResponse'
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> ( Object
x
forall a. FromJSON a => Object -> Key -> Either String (Maybe a)
Data..?> Key
"AvailableLabels"
forall (f :: * -> *) a. Functor f => f (Maybe a) -> a -> f a
Core..!@ forall a. Monoid a => a
Prelude.mempty
)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Either String (Maybe a)
Data..?> Key
"Capacity")
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Either String (Maybe a)
Data..?> Key
"ConsumedLabels" forall (f :: * -> *) a. Functor f => f (Maybe a) -> a -> f a
Core..!@ forall a. Monoid a => a
Prelude.mempty)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Either String (Maybe a)
Data..?> Key
"LabelNamespace")
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Either String (Maybe a)
Data..?> Key
"Rules" forall (f :: * -> *) a. Functor f => f (Maybe a) -> a -> f a
Core..!@ forall a. Monoid a => a
Prelude.mempty)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Either String (Maybe a)
Data..?> Key
"SnsTopicArn")
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Either String (Maybe a)
Data..?> Key
"VersionName")
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure (forall a. Enum a => a -> Int
Prelude.fromEnum Int
s))
)
instance Prelude.Hashable DescribeManagedRuleGroup where
hashWithSalt :: Int -> DescribeManagedRuleGroup -> Int
hashWithSalt Int
_salt DescribeManagedRuleGroup' {Maybe Text
Text
Scope
scope :: Scope
name :: Text
vendorName :: Text
versionName :: Maybe Text
$sel:scope:DescribeManagedRuleGroup' :: DescribeManagedRuleGroup -> Scope
$sel:name:DescribeManagedRuleGroup' :: DescribeManagedRuleGroup -> Text
$sel:vendorName:DescribeManagedRuleGroup' :: DescribeManagedRuleGroup -> Text
$sel:versionName:DescribeManagedRuleGroup' :: DescribeManagedRuleGroup -> Maybe Text
..} =
Int
_salt
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
versionName
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Text
vendorName
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Text
name
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Scope
scope
instance Prelude.NFData DescribeManagedRuleGroup where
rnf :: DescribeManagedRuleGroup -> ()
rnf DescribeManagedRuleGroup' {Maybe Text
Text
Scope
scope :: Scope
name :: Text
vendorName :: Text
versionName :: Maybe Text
$sel:scope:DescribeManagedRuleGroup' :: DescribeManagedRuleGroup -> Scope
$sel:name:DescribeManagedRuleGroup' :: DescribeManagedRuleGroup -> Text
$sel:vendorName:DescribeManagedRuleGroup' :: DescribeManagedRuleGroup -> Text
$sel:versionName:DescribeManagedRuleGroup' :: DescribeManagedRuleGroup -> Maybe Text
..} =
forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
versionName
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Text
vendorName
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Text
name
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Scope
scope
instance Data.ToHeaders DescribeManagedRuleGroup where
toHeaders :: DescribeManagedRuleGroup -> ResponseHeaders
toHeaders =
forall a b. a -> b -> a
Prelude.const
( forall a. Monoid a => [a] -> a
Prelude.mconcat
[ HeaderName
"X-Amz-Target"
forall a. ToHeader a => HeaderName -> a -> ResponseHeaders
Data.=# ( ByteString
"AWSWAF_20190729.DescribeManagedRuleGroup" ::
Prelude.ByteString
),
HeaderName
"Content-Type"
forall a. ToHeader a => HeaderName -> a -> ResponseHeaders
Data.=# ( ByteString
"application/x-amz-json-1.1" ::
Prelude.ByteString
)
]
)
instance Data.ToJSON DescribeManagedRuleGroup where
toJSON :: DescribeManagedRuleGroup -> Value
toJSON DescribeManagedRuleGroup' {Maybe Text
Text
Scope
scope :: Scope
name :: Text
vendorName :: Text
versionName :: Maybe Text
$sel:scope:DescribeManagedRuleGroup' :: DescribeManagedRuleGroup -> Scope
$sel:name:DescribeManagedRuleGroup' :: DescribeManagedRuleGroup -> Text
$sel:vendorName:DescribeManagedRuleGroup' :: DescribeManagedRuleGroup -> Text
$sel:versionName:DescribeManagedRuleGroup' :: DescribeManagedRuleGroup -> Maybe Text
..} =
[Pair] -> Value
Data.object
( forall a. [Maybe a] -> [a]
Prelude.catMaybes
[ (Key
"VersionName" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=) forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Text
versionName,
forall a. a -> Maybe a
Prelude.Just (Key
"VendorName" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..= Text
vendorName),
forall a. a -> Maybe a
Prelude.Just (Key
"Name" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..= Text
name),
forall a. a -> Maybe a
Prelude.Just (Key
"Scope" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..= Scope
scope)
]
)
instance Data.ToPath DescribeManagedRuleGroup where
toPath :: DescribeManagedRuleGroup -> ByteString
toPath = forall a b. a -> b -> a
Prelude.const ByteString
"/"
instance Data.ToQuery DescribeManagedRuleGroup where
toQuery :: DescribeManagedRuleGroup -> QueryString
toQuery = forall a b. a -> b -> a
Prelude.const forall a. Monoid a => a
Prelude.mempty
data DescribeManagedRuleGroupResponse = DescribeManagedRuleGroupResponse'
{
DescribeManagedRuleGroupResponse -> Maybe [LabelSummary]
availableLabels :: Prelude.Maybe [LabelSummary],
DescribeManagedRuleGroupResponse -> Maybe Natural
capacity :: Prelude.Maybe Prelude.Natural,
DescribeManagedRuleGroupResponse -> Maybe [LabelSummary]
consumedLabels :: Prelude.Maybe [LabelSummary],
DescribeManagedRuleGroupResponse -> Maybe Text
labelNamespace :: Prelude.Maybe Prelude.Text,
DescribeManagedRuleGroupResponse -> Maybe [RuleSummary]
rules :: Prelude.Maybe [RuleSummary],
DescribeManagedRuleGroupResponse -> Maybe Text
snsTopicArn :: Prelude.Maybe Prelude.Text,
DescribeManagedRuleGroupResponse -> Maybe Text
versionName :: Prelude.Maybe Prelude.Text,
DescribeManagedRuleGroupResponse -> Int
httpStatus :: Prelude.Int
}
deriving (DescribeManagedRuleGroupResponse
-> DescribeManagedRuleGroupResponse -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: DescribeManagedRuleGroupResponse
-> DescribeManagedRuleGroupResponse -> Bool
$c/= :: DescribeManagedRuleGroupResponse
-> DescribeManagedRuleGroupResponse -> Bool
== :: DescribeManagedRuleGroupResponse
-> DescribeManagedRuleGroupResponse -> Bool
$c== :: DescribeManagedRuleGroupResponse
-> DescribeManagedRuleGroupResponse -> Bool
Prelude.Eq, ReadPrec [DescribeManagedRuleGroupResponse]
ReadPrec DescribeManagedRuleGroupResponse
Int -> ReadS DescribeManagedRuleGroupResponse
ReadS [DescribeManagedRuleGroupResponse]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [DescribeManagedRuleGroupResponse]
$creadListPrec :: ReadPrec [DescribeManagedRuleGroupResponse]
readPrec :: ReadPrec DescribeManagedRuleGroupResponse
$creadPrec :: ReadPrec DescribeManagedRuleGroupResponse
readList :: ReadS [DescribeManagedRuleGroupResponse]
$creadList :: ReadS [DescribeManagedRuleGroupResponse]
readsPrec :: Int -> ReadS DescribeManagedRuleGroupResponse
$creadsPrec :: Int -> ReadS DescribeManagedRuleGroupResponse
Prelude.Read, Int -> DescribeManagedRuleGroupResponse -> ShowS
[DescribeManagedRuleGroupResponse] -> ShowS
DescribeManagedRuleGroupResponse -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [DescribeManagedRuleGroupResponse] -> ShowS
$cshowList :: [DescribeManagedRuleGroupResponse] -> ShowS
show :: DescribeManagedRuleGroupResponse -> String
$cshow :: DescribeManagedRuleGroupResponse -> String
showsPrec :: Int -> DescribeManagedRuleGroupResponse -> ShowS
$cshowsPrec :: Int -> DescribeManagedRuleGroupResponse -> ShowS
Prelude.Show, forall x.
Rep DescribeManagedRuleGroupResponse x
-> DescribeManagedRuleGroupResponse
forall x.
DescribeManagedRuleGroupResponse
-> Rep DescribeManagedRuleGroupResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep DescribeManagedRuleGroupResponse x
-> DescribeManagedRuleGroupResponse
$cfrom :: forall x.
DescribeManagedRuleGroupResponse
-> Rep DescribeManagedRuleGroupResponse x
Prelude.Generic)
newDescribeManagedRuleGroupResponse ::
Prelude.Int ->
DescribeManagedRuleGroupResponse
newDescribeManagedRuleGroupResponse :: Int -> DescribeManagedRuleGroupResponse
newDescribeManagedRuleGroupResponse Int
pHttpStatus_ =
DescribeManagedRuleGroupResponse'
{ $sel:availableLabels:DescribeManagedRuleGroupResponse' :: Maybe [LabelSummary]
availableLabels =
forall a. Maybe a
Prelude.Nothing,
$sel:capacity:DescribeManagedRuleGroupResponse' :: Maybe Natural
capacity = forall a. Maybe a
Prelude.Nothing,
$sel:consumedLabels:DescribeManagedRuleGroupResponse' :: Maybe [LabelSummary]
consumedLabels = forall a. Maybe a
Prelude.Nothing,
$sel:labelNamespace:DescribeManagedRuleGroupResponse' :: Maybe Text
labelNamespace = forall a. Maybe a
Prelude.Nothing,
$sel:rules:DescribeManagedRuleGroupResponse' :: Maybe [RuleSummary]
rules = forall a. Maybe a
Prelude.Nothing,
$sel:snsTopicArn:DescribeManagedRuleGroupResponse' :: Maybe Text
snsTopicArn = forall a. Maybe a
Prelude.Nothing,
$sel:versionName:DescribeManagedRuleGroupResponse' :: Maybe Text
versionName = forall a. Maybe a
Prelude.Nothing,
$sel:httpStatus:DescribeManagedRuleGroupResponse' :: Int
httpStatus = Int
pHttpStatus_
}
describeManagedRuleGroupResponse_availableLabels :: Lens.Lens' DescribeManagedRuleGroupResponse (Prelude.Maybe [LabelSummary])
describeManagedRuleGroupResponse_availableLabels :: Lens' DescribeManagedRuleGroupResponse (Maybe [LabelSummary])
describeManagedRuleGroupResponse_availableLabels = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DescribeManagedRuleGroupResponse' {Maybe [LabelSummary]
availableLabels :: Maybe [LabelSummary]
$sel:availableLabels:DescribeManagedRuleGroupResponse' :: DescribeManagedRuleGroupResponse -> Maybe [LabelSummary]
availableLabels} -> Maybe [LabelSummary]
availableLabels) (\s :: DescribeManagedRuleGroupResponse
s@DescribeManagedRuleGroupResponse' {} Maybe [LabelSummary]
a -> DescribeManagedRuleGroupResponse
s {$sel:availableLabels:DescribeManagedRuleGroupResponse' :: Maybe [LabelSummary]
availableLabels = Maybe [LabelSummary]
a} :: DescribeManagedRuleGroupResponse) forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. 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 forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced
describeManagedRuleGroupResponse_capacity :: Lens.Lens' DescribeManagedRuleGroupResponse (Prelude.Maybe Prelude.Natural)
describeManagedRuleGroupResponse_capacity :: Lens' DescribeManagedRuleGroupResponse (Maybe Natural)
describeManagedRuleGroupResponse_capacity = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DescribeManagedRuleGroupResponse' {Maybe Natural
capacity :: Maybe Natural
$sel:capacity:DescribeManagedRuleGroupResponse' :: DescribeManagedRuleGroupResponse -> Maybe Natural
capacity} -> Maybe Natural
capacity) (\s :: DescribeManagedRuleGroupResponse
s@DescribeManagedRuleGroupResponse' {} Maybe Natural
a -> DescribeManagedRuleGroupResponse
s {$sel:capacity:DescribeManagedRuleGroupResponse' :: Maybe Natural
capacity = Maybe Natural
a} :: DescribeManagedRuleGroupResponse)
describeManagedRuleGroupResponse_consumedLabels :: Lens.Lens' DescribeManagedRuleGroupResponse (Prelude.Maybe [LabelSummary])
describeManagedRuleGroupResponse_consumedLabels :: Lens' DescribeManagedRuleGroupResponse (Maybe [LabelSummary])
describeManagedRuleGroupResponse_consumedLabels = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DescribeManagedRuleGroupResponse' {Maybe [LabelSummary]
consumedLabels :: Maybe [LabelSummary]
$sel:consumedLabels:DescribeManagedRuleGroupResponse' :: DescribeManagedRuleGroupResponse -> Maybe [LabelSummary]
consumedLabels} -> Maybe [LabelSummary]
consumedLabels) (\s :: DescribeManagedRuleGroupResponse
s@DescribeManagedRuleGroupResponse' {} Maybe [LabelSummary]
a -> DescribeManagedRuleGroupResponse
s {$sel:consumedLabels:DescribeManagedRuleGroupResponse' :: Maybe [LabelSummary]
consumedLabels = Maybe [LabelSummary]
a} :: DescribeManagedRuleGroupResponse) forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. 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 forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced
describeManagedRuleGroupResponse_labelNamespace :: Lens.Lens' DescribeManagedRuleGroupResponse (Prelude.Maybe Prelude.Text)
describeManagedRuleGroupResponse_labelNamespace :: Lens' DescribeManagedRuleGroupResponse (Maybe Text)
describeManagedRuleGroupResponse_labelNamespace = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DescribeManagedRuleGroupResponse' {Maybe Text
labelNamespace :: Maybe Text
$sel:labelNamespace:DescribeManagedRuleGroupResponse' :: DescribeManagedRuleGroupResponse -> Maybe Text
labelNamespace} -> Maybe Text
labelNamespace) (\s :: DescribeManagedRuleGroupResponse
s@DescribeManagedRuleGroupResponse' {} Maybe Text
a -> DescribeManagedRuleGroupResponse
s {$sel:labelNamespace:DescribeManagedRuleGroupResponse' :: Maybe Text
labelNamespace = Maybe Text
a} :: DescribeManagedRuleGroupResponse)
describeManagedRuleGroupResponse_rules :: Lens.Lens' DescribeManagedRuleGroupResponse (Prelude.Maybe [RuleSummary])
describeManagedRuleGroupResponse_rules :: Lens' DescribeManagedRuleGroupResponse (Maybe [RuleSummary])
describeManagedRuleGroupResponse_rules = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DescribeManagedRuleGroupResponse' {Maybe [RuleSummary]
rules :: Maybe [RuleSummary]
$sel:rules:DescribeManagedRuleGroupResponse' :: DescribeManagedRuleGroupResponse -> Maybe [RuleSummary]
rules} -> Maybe [RuleSummary]
rules) (\s :: DescribeManagedRuleGroupResponse
s@DescribeManagedRuleGroupResponse' {} Maybe [RuleSummary]
a -> DescribeManagedRuleGroupResponse
s {$sel:rules:DescribeManagedRuleGroupResponse' :: Maybe [RuleSummary]
rules = Maybe [RuleSummary]
a} :: DescribeManagedRuleGroupResponse) forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. 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 forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced
describeManagedRuleGroupResponse_snsTopicArn :: Lens.Lens' DescribeManagedRuleGroupResponse (Prelude.Maybe Prelude.Text)
describeManagedRuleGroupResponse_snsTopicArn :: Lens' DescribeManagedRuleGroupResponse (Maybe Text)
describeManagedRuleGroupResponse_snsTopicArn = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DescribeManagedRuleGroupResponse' {Maybe Text
snsTopicArn :: Maybe Text
$sel:snsTopicArn:DescribeManagedRuleGroupResponse' :: DescribeManagedRuleGroupResponse -> Maybe Text
snsTopicArn} -> Maybe Text
snsTopicArn) (\s :: DescribeManagedRuleGroupResponse
s@DescribeManagedRuleGroupResponse' {} Maybe Text
a -> DescribeManagedRuleGroupResponse
s {$sel:snsTopicArn:DescribeManagedRuleGroupResponse' :: Maybe Text
snsTopicArn = Maybe Text
a} :: DescribeManagedRuleGroupResponse)
describeManagedRuleGroupResponse_versionName :: Lens.Lens' DescribeManagedRuleGroupResponse (Prelude.Maybe Prelude.Text)
describeManagedRuleGroupResponse_versionName :: Lens' DescribeManagedRuleGroupResponse (Maybe Text)
describeManagedRuleGroupResponse_versionName = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DescribeManagedRuleGroupResponse' {Maybe Text
versionName :: Maybe Text
$sel:versionName:DescribeManagedRuleGroupResponse' :: DescribeManagedRuleGroupResponse -> Maybe Text
versionName} -> Maybe Text
versionName) (\s :: DescribeManagedRuleGroupResponse
s@DescribeManagedRuleGroupResponse' {} Maybe Text
a -> DescribeManagedRuleGroupResponse
s {$sel:versionName:DescribeManagedRuleGroupResponse' :: Maybe Text
versionName = Maybe Text
a} :: DescribeManagedRuleGroupResponse)
describeManagedRuleGroupResponse_httpStatus :: Lens.Lens' DescribeManagedRuleGroupResponse Prelude.Int
describeManagedRuleGroupResponse_httpStatus :: Lens' DescribeManagedRuleGroupResponse Int
describeManagedRuleGroupResponse_httpStatus = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DescribeManagedRuleGroupResponse' {Int
httpStatus :: Int
$sel:httpStatus:DescribeManagedRuleGroupResponse' :: DescribeManagedRuleGroupResponse -> Int
httpStatus} -> Int
httpStatus) (\s :: DescribeManagedRuleGroupResponse
s@DescribeManagedRuleGroupResponse' {} Int
a -> DescribeManagedRuleGroupResponse
s {$sel:httpStatus:DescribeManagedRuleGroupResponse' :: Int
httpStatus = Int
a} :: DescribeManagedRuleGroupResponse)
instance
Prelude.NFData
DescribeManagedRuleGroupResponse
where
rnf :: DescribeManagedRuleGroupResponse -> ()
rnf DescribeManagedRuleGroupResponse' {Int
Maybe Natural
Maybe [LabelSummary]
Maybe [RuleSummary]
Maybe Text
httpStatus :: Int
versionName :: Maybe Text
snsTopicArn :: Maybe Text
rules :: Maybe [RuleSummary]
labelNamespace :: Maybe Text
consumedLabels :: Maybe [LabelSummary]
capacity :: Maybe Natural
availableLabels :: Maybe [LabelSummary]
$sel:httpStatus:DescribeManagedRuleGroupResponse' :: DescribeManagedRuleGroupResponse -> Int
$sel:versionName:DescribeManagedRuleGroupResponse' :: DescribeManagedRuleGroupResponse -> Maybe Text
$sel:snsTopicArn:DescribeManagedRuleGroupResponse' :: DescribeManagedRuleGroupResponse -> Maybe Text
$sel:rules:DescribeManagedRuleGroupResponse' :: DescribeManagedRuleGroupResponse -> Maybe [RuleSummary]
$sel:labelNamespace:DescribeManagedRuleGroupResponse' :: DescribeManagedRuleGroupResponse -> Maybe Text
$sel:consumedLabels:DescribeManagedRuleGroupResponse' :: DescribeManagedRuleGroupResponse -> Maybe [LabelSummary]
$sel:capacity:DescribeManagedRuleGroupResponse' :: DescribeManagedRuleGroupResponse -> Maybe Natural
$sel:availableLabels:DescribeManagedRuleGroupResponse' :: DescribeManagedRuleGroupResponse -> Maybe [LabelSummary]
..} =
forall a. NFData a => a -> ()
Prelude.rnf Maybe [LabelSummary]
availableLabels
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Natural
capacity
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe [LabelSummary]
consumedLabels
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
labelNamespace
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe [RuleSummary]
rules
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
snsTopicArn
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
versionName
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Int
httpStatus