module Stratosphere.EC2.NetworkInsightsAccessScope (
module Exports, NetworkInsightsAccessScope(..),
mkNetworkInsightsAccessScope
) where
import qualified Data.Aeson as JSON
import qualified Stratosphere.Prelude as Prelude
import Stratosphere.Property
import {-# SOURCE #-} Stratosphere.EC2.NetworkInsightsAccessScope.AccessScopePathRequestProperty as Exports
import Stratosphere.ResourceProperties
import Stratosphere.Tag
data NetworkInsightsAccessScope
=
NetworkInsightsAccessScope {NetworkInsightsAccessScope -> ()
haddock_workaround_ :: (),
NetworkInsightsAccessScope
-> Maybe [AccessScopePathRequestProperty]
excludePaths :: (Prelude.Maybe [AccessScopePathRequestProperty]),
NetworkInsightsAccessScope
-> Maybe [AccessScopePathRequestProperty]
matchPaths :: (Prelude.Maybe [AccessScopePathRequestProperty]),
NetworkInsightsAccessScope -> Maybe [Tag]
tags :: (Prelude.Maybe [Tag])}
deriving stock (NetworkInsightsAccessScope -> NetworkInsightsAccessScope -> Bool
(NetworkInsightsAccessScope -> NetworkInsightsAccessScope -> Bool)
-> (NetworkInsightsAccessScope
-> NetworkInsightsAccessScope -> Bool)
-> Eq NetworkInsightsAccessScope
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: NetworkInsightsAccessScope -> NetworkInsightsAccessScope -> Bool
== :: NetworkInsightsAccessScope -> NetworkInsightsAccessScope -> Bool
$c/= :: NetworkInsightsAccessScope -> NetworkInsightsAccessScope -> Bool
/= :: NetworkInsightsAccessScope -> NetworkInsightsAccessScope -> Bool
Prelude.Eq, Int -> NetworkInsightsAccessScope -> ShowS
[NetworkInsightsAccessScope] -> ShowS
NetworkInsightsAccessScope -> String
(Int -> NetworkInsightsAccessScope -> ShowS)
-> (NetworkInsightsAccessScope -> String)
-> ([NetworkInsightsAccessScope] -> ShowS)
-> Show NetworkInsightsAccessScope
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> NetworkInsightsAccessScope -> ShowS
showsPrec :: Int -> NetworkInsightsAccessScope -> ShowS
$cshow :: NetworkInsightsAccessScope -> String
show :: NetworkInsightsAccessScope -> String
$cshowList :: [NetworkInsightsAccessScope] -> ShowS
showList :: [NetworkInsightsAccessScope] -> ShowS
Prelude.Show)
mkNetworkInsightsAccessScope :: NetworkInsightsAccessScope
mkNetworkInsightsAccessScope :: NetworkInsightsAccessScope
mkNetworkInsightsAccessScope
= NetworkInsightsAccessScope
{haddock_workaround_ :: ()
haddock_workaround_ = (), excludePaths :: Maybe [AccessScopePathRequestProperty]
excludePaths = Maybe [AccessScopePathRequestProperty]
forall a. Maybe a
Prelude.Nothing,
matchPaths :: Maybe [AccessScopePathRequestProperty]
matchPaths = Maybe [AccessScopePathRequestProperty]
forall a. Maybe a
Prelude.Nothing, tags :: Maybe [Tag]
tags = Maybe [Tag]
forall a. Maybe a
Prelude.Nothing}
instance ToResourceProperties NetworkInsightsAccessScope where
toResourceProperties :: NetworkInsightsAccessScope -> ResourceProperties
toResourceProperties NetworkInsightsAccessScope {Maybe [Tag]
Maybe [AccessScopePathRequestProperty]
()
haddock_workaround_ :: NetworkInsightsAccessScope -> ()
excludePaths :: NetworkInsightsAccessScope
-> Maybe [AccessScopePathRequestProperty]
matchPaths :: NetworkInsightsAccessScope
-> Maybe [AccessScopePathRequestProperty]
tags :: NetworkInsightsAccessScope -> Maybe [Tag]
haddock_workaround_ :: ()
excludePaths :: Maybe [AccessScopePathRequestProperty]
matchPaths :: Maybe [AccessScopePathRequestProperty]
tags :: Maybe [Tag]
..}
= ResourceProperties
{awsType :: Text
awsType = Text
"AWS::EC2::NetworkInsightsAccessScope",
supportsTags :: Bool
supportsTags = Bool
Prelude.True,
properties :: Object
properties = [Item Object] -> Object
forall l. IsList l => [Item l] -> l
Prelude.fromList
([Maybe (Key, Value)] -> [(Key, Value)]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
[Key -> [AccessScopePathRequestProperty] -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"ExcludePaths" ([AccessScopePathRequestProperty] -> (Key, Value))
-> Maybe [AccessScopePathRequestProperty] -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe [AccessScopePathRequestProperty]
excludePaths,
Key -> [AccessScopePathRequestProperty] -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"MatchPaths" ([AccessScopePathRequestProperty] -> (Key, Value))
-> Maybe [AccessScopePathRequestProperty] -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe [AccessScopePathRequestProperty]
matchPaths,
Key -> [Tag] -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"Tags" ([Tag] -> (Key, Value)) -> Maybe [Tag] -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe [Tag]
tags])}
instance JSON.ToJSON NetworkInsightsAccessScope where
toJSON :: NetworkInsightsAccessScope -> Value
toJSON NetworkInsightsAccessScope {Maybe [Tag]
Maybe [AccessScopePathRequestProperty]
()
haddock_workaround_ :: NetworkInsightsAccessScope -> ()
excludePaths :: NetworkInsightsAccessScope
-> Maybe [AccessScopePathRequestProperty]
matchPaths :: NetworkInsightsAccessScope
-> Maybe [AccessScopePathRequestProperty]
tags :: NetworkInsightsAccessScope -> Maybe [Tag]
haddock_workaround_ :: ()
excludePaths :: Maybe [AccessScopePathRequestProperty]
matchPaths :: Maybe [AccessScopePathRequestProperty]
tags :: Maybe [Tag]
..}
= [(Key, Value)] -> Value
JSON.object
([Item [(Key, Value)]] -> [(Key, Value)]
forall l. IsList l => [Item l] -> l
Prelude.fromList
([Maybe (Key, Value)] -> [(Key, Value)]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
[Key -> [AccessScopePathRequestProperty] -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"ExcludePaths" ([AccessScopePathRequestProperty] -> (Key, Value))
-> Maybe [AccessScopePathRequestProperty] -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe [AccessScopePathRequestProperty]
excludePaths,
Key -> [AccessScopePathRequestProperty] -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"MatchPaths" ([AccessScopePathRequestProperty] -> (Key, Value))
-> Maybe [AccessScopePathRequestProperty] -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe [AccessScopePathRequestProperty]
matchPaths,
Key -> [Tag] -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"Tags" ([Tag] -> (Key, Value)) -> Maybe [Tag] -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe [Tag]
tags]))
instance Property "ExcludePaths" NetworkInsightsAccessScope where
type PropertyType "ExcludePaths" NetworkInsightsAccessScope = [AccessScopePathRequestProperty]
set :: PropertyType "ExcludePaths" NetworkInsightsAccessScope
-> NetworkInsightsAccessScope -> NetworkInsightsAccessScope
set PropertyType "ExcludePaths" NetworkInsightsAccessScope
newValue NetworkInsightsAccessScope {Maybe [Tag]
Maybe [AccessScopePathRequestProperty]
()
haddock_workaround_ :: NetworkInsightsAccessScope -> ()
excludePaths :: NetworkInsightsAccessScope
-> Maybe [AccessScopePathRequestProperty]
matchPaths :: NetworkInsightsAccessScope
-> Maybe [AccessScopePathRequestProperty]
tags :: NetworkInsightsAccessScope -> Maybe [Tag]
haddock_workaround_ :: ()
excludePaths :: Maybe [AccessScopePathRequestProperty]
matchPaths :: Maybe [AccessScopePathRequestProperty]
tags :: Maybe [Tag]
..}
= NetworkInsightsAccessScope
{excludePaths :: Maybe [AccessScopePathRequestProperty]
excludePaths = [AccessScopePathRequestProperty]
-> Maybe [AccessScopePathRequestProperty]
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure [AccessScopePathRequestProperty]
PropertyType "ExcludePaths" NetworkInsightsAccessScope
newValue, Maybe [Tag]
Maybe [AccessScopePathRequestProperty]
()
haddock_workaround_ :: ()
matchPaths :: Maybe [AccessScopePathRequestProperty]
tags :: Maybe [Tag]
haddock_workaround_ :: ()
matchPaths :: Maybe [AccessScopePathRequestProperty]
tags :: Maybe [Tag]
..}
instance Property "MatchPaths" NetworkInsightsAccessScope where
type PropertyType "MatchPaths" NetworkInsightsAccessScope = [AccessScopePathRequestProperty]
set :: PropertyType "MatchPaths" NetworkInsightsAccessScope
-> NetworkInsightsAccessScope -> NetworkInsightsAccessScope
set PropertyType "MatchPaths" NetworkInsightsAccessScope
newValue NetworkInsightsAccessScope {Maybe [Tag]
Maybe [AccessScopePathRequestProperty]
()
haddock_workaround_ :: NetworkInsightsAccessScope -> ()
excludePaths :: NetworkInsightsAccessScope
-> Maybe [AccessScopePathRequestProperty]
matchPaths :: NetworkInsightsAccessScope
-> Maybe [AccessScopePathRequestProperty]
tags :: NetworkInsightsAccessScope -> Maybe [Tag]
haddock_workaround_ :: ()
excludePaths :: Maybe [AccessScopePathRequestProperty]
matchPaths :: Maybe [AccessScopePathRequestProperty]
tags :: Maybe [Tag]
..}
= NetworkInsightsAccessScope
{matchPaths :: Maybe [AccessScopePathRequestProperty]
matchPaths = [AccessScopePathRequestProperty]
-> Maybe [AccessScopePathRequestProperty]
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure [AccessScopePathRequestProperty]
PropertyType "MatchPaths" NetworkInsightsAccessScope
newValue, Maybe [Tag]
Maybe [AccessScopePathRequestProperty]
()
haddock_workaround_ :: ()
excludePaths :: Maybe [AccessScopePathRequestProperty]
tags :: Maybe [Tag]
haddock_workaround_ :: ()
excludePaths :: Maybe [AccessScopePathRequestProperty]
tags :: Maybe [Tag]
..}
instance Property "Tags" NetworkInsightsAccessScope where
type PropertyType "Tags" NetworkInsightsAccessScope = [Tag]
set :: PropertyType "Tags" NetworkInsightsAccessScope
-> NetworkInsightsAccessScope -> NetworkInsightsAccessScope
set PropertyType "Tags" NetworkInsightsAccessScope
newValue NetworkInsightsAccessScope {Maybe [Tag]
Maybe [AccessScopePathRequestProperty]
()
haddock_workaround_ :: NetworkInsightsAccessScope -> ()
excludePaths :: NetworkInsightsAccessScope
-> Maybe [AccessScopePathRequestProperty]
matchPaths :: NetworkInsightsAccessScope
-> Maybe [AccessScopePathRequestProperty]
tags :: NetworkInsightsAccessScope -> Maybe [Tag]
haddock_workaround_ :: ()
excludePaths :: Maybe [AccessScopePathRequestProperty]
matchPaths :: Maybe [AccessScopePathRequestProperty]
tags :: Maybe [Tag]
..}
= NetworkInsightsAccessScope {tags :: Maybe [Tag]
tags = [Tag] -> Maybe [Tag]
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure [Tag]
PropertyType "Tags" NetworkInsightsAccessScope
newValue, Maybe [AccessScopePathRequestProperty]
()
haddock_workaround_ :: ()
excludePaths :: Maybe [AccessScopePathRequestProperty]
matchPaths :: Maybe [AccessScopePathRequestProperty]
haddock_workaround_ :: ()
excludePaths :: Maybe [AccessScopePathRequestProperty]
matchPaths :: Maybe [AccessScopePathRequestProperty]
..}