{-# 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.EC2.Types.NetworkBandwidthGbpsRequest where
import qualified Amazonka.Core as Core
import qualified Amazonka.Core.Lens.Internal as Lens
import qualified Amazonka.Data as Data
import Amazonka.EC2.Internal
import qualified Amazonka.Prelude as Prelude
data NetworkBandwidthGbpsRequest = NetworkBandwidthGbpsRequest'
{
NetworkBandwidthGbpsRequest -> Maybe Double
max :: Prelude.Maybe Prelude.Double,
NetworkBandwidthGbpsRequest -> Maybe Double
min :: Prelude.Maybe Prelude.Double
}
deriving (NetworkBandwidthGbpsRequest -> NetworkBandwidthGbpsRequest -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: NetworkBandwidthGbpsRequest -> NetworkBandwidthGbpsRequest -> Bool
$c/= :: NetworkBandwidthGbpsRequest -> NetworkBandwidthGbpsRequest -> Bool
== :: NetworkBandwidthGbpsRequest -> NetworkBandwidthGbpsRequest -> Bool
$c== :: NetworkBandwidthGbpsRequest -> NetworkBandwidthGbpsRequest -> Bool
Prelude.Eq, ReadPrec [NetworkBandwidthGbpsRequest]
ReadPrec NetworkBandwidthGbpsRequest
Int -> ReadS NetworkBandwidthGbpsRequest
ReadS [NetworkBandwidthGbpsRequest]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [NetworkBandwidthGbpsRequest]
$creadListPrec :: ReadPrec [NetworkBandwidthGbpsRequest]
readPrec :: ReadPrec NetworkBandwidthGbpsRequest
$creadPrec :: ReadPrec NetworkBandwidthGbpsRequest
readList :: ReadS [NetworkBandwidthGbpsRequest]
$creadList :: ReadS [NetworkBandwidthGbpsRequest]
readsPrec :: Int -> ReadS NetworkBandwidthGbpsRequest
$creadsPrec :: Int -> ReadS NetworkBandwidthGbpsRequest
Prelude.Read, Int -> NetworkBandwidthGbpsRequest -> ShowS
[NetworkBandwidthGbpsRequest] -> ShowS
NetworkBandwidthGbpsRequest -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [NetworkBandwidthGbpsRequest] -> ShowS
$cshowList :: [NetworkBandwidthGbpsRequest] -> ShowS
show :: NetworkBandwidthGbpsRequest -> String
$cshow :: NetworkBandwidthGbpsRequest -> String
showsPrec :: Int -> NetworkBandwidthGbpsRequest -> ShowS
$cshowsPrec :: Int -> NetworkBandwidthGbpsRequest -> ShowS
Prelude.Show, forall x.
Rep NetworkBandwidthGbpsRequest x -> NetworkBandwidthGbpsRequest
forall x.
NetworkBandwidthGbpsRequest -> Rep NetworkBandwidthGbpsRequest x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep NetworkBandwidthGbpsRequest x -> NetworkBandwidthGbpsRequest
$cfrom :: forall x.
NetworkBandwidthGbpsRequest -> Rep NetworkBandwidthGbpsRequest x
Prelude.Generic)
newNetworkBandwidthGbpsRequest ::
NetworkBandwidthGbpsRequest
newNetworkBandwidthGbpsRequest :: NetworkBandwidthGbpsRequest
newNetworkBandwidthGbpsRequest =
NetworkBandwidthGbpsRequest'
{ $sel:max:NetworkBandwidthGbpsRequest' :: Maybe Double
max = forall a. Maybe a
Prelude.Nothing,
$sel:min:NetworkBandwidthGbpsRequest' :: Maybe Double
min = forall a. Maybe a
Prelude.Nothing
}
networkBandwidthGbpsRequest_max :: Lens.Lens' NetworkBandwidthGbpsRequest (Prelude.Maybe Prelude.Double)
networkBandwidthGbpsRequest_max :: Lens' NetworkBandwidthGbpsRequest (Maybe Double)
networkBandwidthGbpsRequest_max = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\NetworkBandwidthGbpsRequest' {Maybe Double
max :: Maybe Double
$sel:max:NetworkBandwidthGbpsRequest' :: NetworkBandwidthGbpsRequest -> Maybe Double
max} -> Maybe Double
max) (\s :: NetworkBandwidthGbpsRequest
s@NetworkBandwidthGbpsRequest' {} Maybe Double
a -> NetworkBandwidthGbpsRequest
s {$sel:max:NetworkBandwidthGbpsRequest' :: Maybe Double
max = Maybe Double
a} :: NetworkBandwidthGbpsRequest)
networkBandwidthGbpsRequest_min :: Lens.Lens' NetworkBandwidthGbpsRequest (Prelude.Maybe Prelude.Double)
networkBandwidthGbpsRequest_min :: Lens' NetworkBandwidthGbpsRequest (Maybe Double)
networkBandwidthGbpsRequest_min = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\NetworkBandwidthGbpsRequest' {Maybe Double
min :: Maybe Double
$sel:min:NetworkBandwidthGbpsRequest' :: NetworkBandwidthGbpsRequest -> Maybe Double
min} -> Maybe Double
min) (\s :: NetworkBandwidthGbpsRequest
s@NetworkBandwidthGbpsRequest' {} Maybe Double
a -> NetworkBandwidthGbpsRequest
s {$sel:min:NetworkBandwidthGbpsRequest' :: Maybe Double
min = Maybe Double
a} :: NetworkBandwidthGbpsRequest)
instance Prelude.Hashable NetworkBandwidthGbpsRequest where
hashWithSalt :: Int -> NetworkBandwidthGbpsRequest -> Int
hashWithSalt Int
_salt NetworkBandwidthGbpsRequest' {Maybe Double
min :: Maybe Double
max :: Maybe Double
$sel:min:NetworkBandwidthGbpsRequest' :: NetworkBandwidthGbpsRequest -> Maybe Double
$sel:max:NetworkBandwidthGbpsRequest' :: NetworkBandwidthGbpsRequest -> Maybe Double
..} =
Int
_salt
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Double
max
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Double
min
instance Prelude.NFData NetworkBandwidthGbpsRequest where
rnf :: NetworkBandwidthGbpsRequest -> ()
rnf NetworkBandwidthGbpsRequest' {Maybe Double
min :: Maybe Double
max :: Maybe Double
$sel:min:NetworkBandwidthGbpsRequest' :: NetworkBandwidthGbpsRequest -> Maybe Double
$sel:max:NetworkBandwidthGbpsRequest' :: NetworkBandwidthGbpsRequest -> Maybe Double
..} =
forall a. NFData a => a -> ()
Prelude.rnf Maybe Double
max seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Double
min
instance Data.ToQuery NetworkBandwidthGbpsRequest where
toQuery :: NetworkBandwidthGbpsRequest -> QueryString
toQuery NetworkBandwidthGbpsRequest' {Maybe Double
min :: Maybe Double
max :: Maybe Double
$sel:min:NetworkBandwidthGbpsRequest' :: NetworkBandwidthGbpsRequest -> Maybe Double
$sel:max:NetworkBandwidthGbpsRequest' :: NetworkBandwidthGbpsRequest -> Maybe Double
..} =
forall a. Monoid a => [a] -> a
Prelude.mconcat
[ByteString
"Max" forall a. ToQuery a => ByteString -> a -> QueryString
Data.=: Maybe Double
max, ByteString
"Min" forall a. ToQuery a => ByteString -> a -> QueryString
Data.=: Maybe Double
min]