{-# 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.ProcessType 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 ProcessType = ProcessType'
{
ProcessType -> Text
processName :: Prelude.Text
}
deriving (ProcessType -> ProcessType -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: ProcessType -> ProcessType -> Bool
$c/= :: ProcessType -> ProcessType -> Bool
== :: ProcessType -> ProcessType -> Bool
$c== :: ProcessType -> ProcessType -> Bool
Prelude.Eq, ReadPrec [ProcessType]
ReadPrec ProcessType
Int -> ReadS ProcessType
ReadS [ProcessType]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [ProcessType]
$creadListPrec :: ReadPrec [ProcessType]
readPrec :: ReadPrec ProcessType
$creadPrec :: ReadPrec ProcessType
readList :: ReadS [ProcessType]
$creadList :: ReadS [ProcessType]
readsPrec :: Int -> ReadS ProcessType
$creadsPrec :: Int -> ReadS ProcessType
Prelude.Read, Int -> ProcessType -> ShowS
[ProcessType] -> ShowS
ProcessType -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [ProcessType] -> ShowS
$cshowList :: [ProcessType] -> ShowS
show :: ProcessType -> String
$cshow :: ProcessType -> String
showsPrec :: Int -> ProcessType -> ShowS
$cshowsPrec :: Int -> ProcessType -> ShowS
Prelude.Show, forall x. Rep ProcessType x -> ProcessType
forall x. ProcessType -> Rep ProcessType x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep ProcessType x -> ProcessType
$cfrom :: forall x. ProcessType -> Rep ProcessType x
Prelude.Generic)
newProcessType ::
Prelude.Text ->
ProcessType
newProcessType :: Text -> ProcessType
newProcessType Text
pProcessName_ =
ProcessType' {$sel:processName:ProcessType' :: Text
processName = Text
pProcessName_}
processType_processName :: Lens.Lens' ProcessType Prelude.Text
processType_processName :: Lens' ProcessType Text
processType_processName = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ProcessType' {Text
processName :: Text
$sel:processName:ProcessType' :: ProcessType -> Text
processName} -> Text
processName) (\s :: ProcessType
s@ProcessType' {} Text
a -> ProcessType
s {$sel:processName:ProcessType' :: Text
processName = Text
a} :: ProcessType)
instance Data.FromXML ProcessType where
parseXML :: [Node] -> Either String ProcessType
parseXML [Node]
x =
Text -> ProcessType
ProcessType' forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> ([Node]
x forall a. FromXML a => [Node] -> Text -> Either String a
Data..@ Text
"ProcessName")
instance Prelude.Hashable ProcessType where
hashWithSalt :: Int -> ProcessType -> Int
hashWithSalt Int
_salt ProcessType' {Text
processName :: Text
$sel:processName:ProcessType' :: ProcessType -> Text
..} =
Int
_salt forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Text
processName
instance Prelude.NFData ProcessType where
rnf :: ProcessType -> ()
rnf ProcessType' {Text
processName :: Text
$sel:processName:ProcessType' :: ProcessType -> Text
..} = forall a. NFData a => a -> ()
Prelude.rnf Text
processName