{-# 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.AutoScaling.Types.ScalingProcessQuery 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
data ScalingProcessQuery = ScalingProcessQuery'
{
ScalingProcessQuery -> Maybe [Text]
scalingProcesses :: Prelude.Maybe [Prelude.Text],
ScalingProcessQuery -> Text
autoScalingGroupName :: Prelude.Text
}
deriving (ScalingProcessQuery -> ScalingProcessQuery -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: ScalingProcessQuery -> ScalingProcessQuery -> Bool
$c/= :: ScalingProcessQuery -> ScalingProcessQuery -> Bool
== :: ScalingProcessQuery -> ScalingProcessQuery -> Bool
$c== :: ScalingProcessQuery -> ScalingProcessQuery -> Bool
Prelude.Eq, ReadPrec [ScalingProcessQuery]
ReadPrec ScalingProcessQuery
Int -> ReadS ScalingProcessQuery
ReadS [ScalingProcessQuery]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [ScalingProcessQuery]
$creadListPrec :: ReadPrec [ScalingProcessQuery]
readPrec :: ReadPrec ScalingProcessQuery
$creadPrec :: ReadPrec ScalingProcessQuery
readList :: ReadS [ScalingProcessQuery]
$creadList :: ReadS [ScalingProcessQuery]
readsPrec :: Int -> ReadS ScalingProcessQuery
$creadsPrec :: Int -> ReadS ScalingProcessQuery
Prelude.Read, Int -> ScalingProcessQuery -> ShowS
[ScalingProcessQuery] -> ShowS
ScalingProcessQuery -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [ScalingProcessQuery] -> ShowS
$cshowList :: [ScalingProcessQuery] -> ShowS
show :: ScalingProcessQuery -> String
$cshow :: ScalingProcessQuery -> String
showsPrec :: Int -> ScalingProcessQuery -> ShowS
$cshowsPrec :: Int -> ScalingProcessQuery -> ShowS
Prelude.Show, forall x. Rep ScalingProcessQuery x -> ScalingProcessQuery
forall x. ScalingProcessQuery -> Rep ScalingProcessQuery x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep ScalingProcessQuery x -> ScalingProcessQuery
$cfrom :: forall x. ScalingProcessQuery -> Rep ScalingProcessQuery x
Prelude.Generic)
newScalingProcessQuery ::
Prelude.Text ->
ScalingProcessQuery
newScalingProcessQuery :: Text -> ScalingProcessQuery
newScalingProcessQuery Text
pAutoScalingGroupName_ =
ScalingProcessQuery'
{ $sel:scalingProcesses:ScalingProcessQuery' :: Maybe [Text]
scalingProcesses =
forall a. Maybe a
Prelude.Nothing,
$sel:autoScalingGroupName:ScalingProcessQuery' :: Text
autoScalingGroupName = Text
pAutoScalingGroupName_
}
scalingProcessQuery_scalingProcesses :: Lens.Lens' ScalingProcessQuery (Prelude.Maybe [Prelude.Text])
scalingProcessQuery_scalingProcesses :: Lens' ScalingProcessQuery (Maybe [Text])
scalingProcessQuery_scalingProcesses = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ScalingProcessQuery' {Maybe [Text]
scalingProcesses :: Maybe [Text]
$sel:scalingProcesses:ScalingProcessQuery' :: ScalingProcessQuery -> Maybe [Text]
scalingProcesses} -> Maybe [Text]
scalingProcesses) (\s :: ScalingProcessQuery
s@ScalingProcessQuery' {} Maybe [Text]
a -> ScalingProcessQuery
s {$sel:scalingProcesses:ScalingProcessQuery' :: Maybe [Text]
scalingProcesses = Maybe [Text]
a} :: ScalingProcessQuery) 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
scalingProcessQuery_autoScalingGroupName :: Lens.Lens' ScalingProcessQuery Prelude.Text
scalingProcessQuery_autoScalingGroupName :: Lens' ScalingProcessQuery Text
scalingProcessQuery_autoScalingGroupName = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ScalingProcessQuery' {Text
autoScalingGroupName :: Text
$sel:autoScalingGroupName:ScalingProcessQuery' :: ScalingProcessQuery -> Text
autoScalingGroupName} -> Text
autoScalingGroupName) (\s :: ScalingProcessQuery
s@ScalingProcessQuery' {} Text
a -> ScalingProcessQuery
s {$sel:autoScalingGroupName:ScalingProcessQuery' :: Text
autoScalingGroupName = Text
a} :: ScalingProcessQuery)
instance Prelude.Hashable ScalingProcessQuery where
hashWithSalt :: Int -> ScalingProcessQuery -> Int
hashWithSalt Int
_salt ScalingProcessQuery' {Maybe [Text]
Text
autoScalingGroupName :: Text
scalingProcesses :: Maybe [Text]
$sel:autoScalingGroupName:ScalingProcessQuery' :: ScalingProcessQuery -> Text
$sel:scalingProcesses:ScalingProcessQuery' :: ScalingProcessQuery -> Maybe [Text]
..} =
Int
_salt
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe [Text]
scalingProcesses
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Text
autoScalingGroupName
instance Prelude.NFData ScalingProcessQuery where
rnf :: ScalingProcessQuery -> ()
rnf ScalingProcessQuery' {Maybe [Text]
Text
autoScalingGroupName :: Text
scalingProcesses :: Maybe [Text]
$sel:autoScalingGroupName:ScalingProcessQuery' :: ScalingProcessQuery -> Text
$sel:scalingProcesses:ScalingProcessQuery' :: ScalingProcessQuery -> Maybe [Text]
..} =
forall a. NFData a => a -> ()
Prelude.rnf Maybe [Text]
scalingProcesses
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Text
autoScalingGroupName
instance Data.ToQuery ScalingProcessQuery where
toQuery :: ScalingProcessQuery -> QueryString
toQuery ScalingProcessQuery' {Maybe [Text]
Text
autoScalingGroupName :: Text
scalingProcesses :: Maybe [Text]
$sel:autoScalingGroupName:ScalingProcessQuery' :: ScalingProcessQuery -> Text
$sel:scalingProcesses:ScalingProcessQuery' :: ScalingProcessQuery -> Maybe [Text]
..} =
forall a. Monoid a => [a] -> a
Prelude.mconcat
[ ByteString
"ScalingProcesses"
forall a. ToQuery a => ByteString -> a -> QueryString
Data.=: forall a. ToQuery a => a -> QueryString
Data.toQuery
( forall a.
(IsList a, ToQuery (Item a)) =>
ByteString -> a -> QueryString
Data.toQueryList ByteString
"member"
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe [Text]
scalingProcesses
),
ByteString
"AutoScalingGroupName" forall a. ToQuery a => ByteString -> a -> QueryString
Data.=: Text
autoScalingGroupName
]