{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE DerivingStrategies #-}
{-# LANGUAGE GeneralizedNewtypeDeriving #-}
{-# LANGUAGE LambdaCase #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE PatternSynonyms #-}
{-# LANGUAGE StrictData #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}

-- Derived from AWS service descriptions, licensed under Apache 2.0.

-- |
-- Module      : Amazonka.GameLift.Types.ScalingAdjustmentType
-- Copyright   : (c) 2013-2021 Brendan Hay
-- License     : Mozilla Public License, v. 2.0.
-- Maintainer  : Brendan Hay <brendan.g.hay+amazonka@gmail.com>
-- Stability   : auto-generated
-- Portability : non-portable (GHC extensions)
module Amazonka.GameLift.Types.ScalingAdjustmentType
  ( ScalingAdjustmentType
      ( ..,
        ScalingAdjustmentType_ChangeInCapacity,
        ScalingAdjustmentType_ExactCapacity,
        ScalingAdjustmentType_PercentChangeInCapacity
      ),
  )
where

import qualified Amazonka.Core as Core
import qualified Amazonka.Prelude as Prelude

newtype ScalingAdjustmentType = ScalingAdjustmentType'
  { ScalingAdjustmentType -> Text
fromScalingAdjustmentType ::
      Core.Text
  }
  deriving stock
    ( Int -> ScalingAdjustmentType -> ShowS
[ScalingAdjustmentType] -> ShowS
ScalingAdjustmentType -> String
(Int -> ScalingAdjustmentType -> ShowS)
-> (ScalingAdjustmentType -> String)
-> ([ScalingAdjustmentType] -> ShowS)
-> Show ScalingAdjustmentType
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [ScalingAdjustmentType] -> ShowS
$cshowList :: [ScalingAdjustmentType] -> ShowS
show :: ScalingAdjustmentType -> String
$cshow :: ScalingAdjustmentType -> String
showsPrec :: Int -> ScalingAdjustmentType -> ShowS
$cshowsPrec :: Int -> ScalingAdjustmentType -> ShowS
Prelude.Show,
      ReadPrec [ScalingAdjustmentType]
ReadPrec ScalingAdjustmentType
Int -> ReadS ScalingAdjustmentType
ReadS [ScalingAdjustmentType]
(Int -> ReadS ScalingAdjustmentType)
-> ReadS [ScalingAdjustmentType]
-> ReadPrec ScalingAdjustmentType
-> ReadPrec [ScalingAdjustmentType]
-> Read ScalingAdjustmentType
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [ScalingAdjustmentType]
$creadListPrec :: ReadPrec [ScalingAdjustmentType]
readPrec :: ReadPrec ScalingAdjustmentType
$creadPrec :: ReadPrec ScalingAdjustmentType
readList :: ReadS [ScalingAdjustmentType]
$creadList :: ReadS [ScalingAdjustmentType]
readsPrec :: Int -> ReadS ScalingAdjustmentType
$creadsPrec :: Int -> ReadS ScalingAdjustmentType
Prelude.Read,
      ScalingAdjustmentType -> ScalingAdjustmentType -> Bool
(ScalingAdjustmentType -> ScalingAdjustmentType -> Bool)
-> (ScalingAdjustmentType -> ScalingAdjustmentType -> Bool)
-> Eq ScalingAdjustmentType
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: ScalingAdjustmentType -> ScalingAdjustmentType -> Bool
$c/= :: ScalingAdjustmentType -> ScalingAdjustmentType -> Bool
== :: ScalingAdjustmentType -> ScalingAdjustmentType -> Bool
$c== :: ScalingAdjustmentType -> ScalingAdjustmentType -> Bool
Prelude.Eq,
      Eq ScalingAdjustmentType
Eq ScalingAdjustmentType
-> (ScalingAdjustmentType -> ScalingAdjustmentType -> Ordering)
-> (ScalingAdjustmentType -> ScalingAdjustmentType -> Bool)
-> (ScalingAdjustmentType -> ScalingAdjustmentType -> Bool)
-> (ScalingAdjustmentType -> ScalingAdjustmentType -> Bool)
-> (ScalingAdjustmentType -> ScalingAdjustmentType -> Bool)
-> (ScalingAdjustmentType
    -> ScalingAdjustmentType -> ScalingAdjustmentType)
-> (ScalingAdjustmentType
    -> ScalingAdjustmentType -> ScalingAdjustmentType)
-> Ord ScalingAdjustmentType
ScalingAdjustmentType -> ScalingAdjustmentType -> Bool
ScalingAdjustmentType -> ScalingAdjustmentType -> Ordering
ScalingAdjustmentType
-> ScalingAdjustmentType -> ScalingAdjustmentType
forall a.
Eq a
-> (a -> a -> Ordering)
-> (a -> a -> Bool)
-> (a -> a -> Bool)
-> (a -> a -> Bool)
-> (a -> a -> Bool)
-> (a -> a -> a)
-> (a -> a -> a)
-> Ord a
min :: ScalingAdjustmentType
-> ScalingAdjustmentType -> ScalingAdjustmentType
$cmin :: ScalingAdjustmentType
-> ScalingAdjustmentType -> ScalingAdjustmentType
max :: ScalingAdjustmentType
-> ScalingAdjustmentType -> ScalingAdjustmentType
$cmax :: ScalingAdjustmentType
-> ScalingAdjustmentType -> ScalingAdjustmentType
>= :: ScalingAdjustmentType -> ScalingAdjustmentType -> Bool
$c>= :: ScalingAdjustmentType -> ScalingAdjustmentType -> Bool
> :: ScalingAdjustmentType -> ScalingAdjustmentType -> Bool
$c> :: ScalingAdjustmentType -> ScalingAdjustmentType -> Bool
<= :: ScalingAdjustmentType -> ScalingAdjustmentType -> Bool
$c<= :: ScalingAdjustmentType -> ScalingAdjustmentType -> Bool
< :: ScalingAdjustmentType -> ScalingAdjustmentType -> Bool
$c< :: ScalingAdjustmentType -> ScalingAdjustmentType -> Bool
compare :: ScalingAdjustmentType -> ScalingAdjustmentType -> Ordering
$ccompare :: ScalingAdjustmentType -> ScalingAdjustmentType -> Ordering
$cp1Ord :: Eq ScalingAdjustmentType
Prelude.Ord,
      (forall x. ScalingAdjustmentType -> Rep ScalingAdjustmentType x)
-> (forall x. Rep ScalingAdjustmentType x -> ScalingAdjustmentType)
-> Generic ScalingAdjustmentType
forall x. Rep ScalingAdjustmentType x -> ScalingAdjustmentType
forall x. ScalingAdjustmentType -> Rep ScalingAdjustmentType x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep ScalingAdjustmentType x -> ScalingAdjustmentType
$cfrom :: forall x. ScalingAdjustmentType -> Rep ScalingAdjustmentType x
Prelude.Generic
    )
  deriving newtype
    ( Int -> ScalingAdjustmentType -> Int
ScalingAdjustmentType -> Int
(Int -> ScalingAdjustmentType -> Int)
-> (ScalingAdjustmentType -> Int) -> Hashable ScalingAdjustmentType
forall a. (Int -> a -> Int) -> (a -> Int) -> Hashable a
hash :: ScalingAdjustmentType -> Int
$chash :: ScalingAdjustmentType -> Int
hashWithSalt :: Int -> ScalingAdjustmentType -> Int
$chashWithSalt :: Int -> ScalingAdjustmentType -> Int
Prelude.Hashable,
      ScalingAdjustmentType -> ()
(ScalingAdjustmentType -> ()) -> NFData ScalingAdjustmentType
forall a. (a -> ()) -> NFData a
rnf :: ScalingAdjustmentType -> ()
$crnf :: ScalingAdjustmentType -> ()
Prelude.NFData,
      Text -> Either String ScalingAdjustmentType
(Text -> Either String ScalingAdjustmentType)
-> FromText ScalingAdjustmentType
forall a. (Text -> Either String a) -> FromText a
fromText :: Text -> Either String ScalingAdjustmentType
$cfromText :: Text -> Either String ScalingAdjustmentType
Core.FromText,
      ScalingAdjustmentType -> Text
(ScalingAdjustmentType -> Text) -> ToText ScalingAdjustmentType
forall a. (a -> Text) -> ToText a
toText :: ScalingAdjustmentType -> Text
$ctoText :: ScalingAdjustmentType -> Text
Core.ToText,
      ScalingAdjustmentType -> ByteString
(ScalingAdjustmentType -> ByteString)
-> ToByteString ScalingAdjustmentType
forall a. (a -> ByteString) -> ToByteString a
toBS :: ScalingAdjustmentType -> ByteString
$ctoBS :: ScalingAdjustmentType -> ByteString
Core.ToByteString,
      ScalingAdjustmentType -> ByteStringBuilder
(ScalingAdjustmentType -> ByteStringBuilder)
-> ToLog ScalingAdjustmentType
forall a. (a -> ByteStringBuilder) -> ToLog a
build :: ScalingAdjustmentType -> ByteStringBuilder
$cbuild :: ScalingAdjustmentType -> ByteStringBuilder
Core.ToLog,
      HeaderName -> ScalingAdjustmentType -> [Header]
(HeaderName -> ScalingAdjustmentType -> [Header])
-> ToHeader ScalingAdjustmentType
forall a. (HeaderName -> a -> [Header]) -> ToHeader a
toHeader :: HeaderName -> ScalingAdjustmentType -> [Header]
$ctoHeader :: HeaderName -> ScalingAdjustmentType -> [Header]
Core.ToHeader,
      ScalingAdjustmentType -> QueryString
(ScalingAdjustmentType -> QueryString)
-> ToQuery ScalingAdjustmentType
forall a. (a -> QueryString) -> ToQuery a
toQuery :: ScalingAdjustmentType -> QueryString
$ctoQuery :: ScalingAdjustmentType -> QueryString
Core.ToQuery,
      Value -> Parser [ScalingAdjustmentType]
Value -> Parser ScalingAdjustmentType
(Value -> Parser ScalingAdjustmentType)
-> (Value -> Parser [ScalingAdjustmentType])
-> FromJSON ScalingAdjustmentType
forall a.
(Value -> Parser a) -> (Value -> Parser [a]) -> FromJSON a
parseJSONList :: Value -> Parser [ScalingAdjustmentType]
$cparseJSONList :: Value -> Parser [ScalingAdjustmentType]
parseJSON :: Value -> Parser ScalingAdjustmentType
$cparseJSON :: Value -> Parser ScalingAdjustmentType
Core.FromJSON,
      FromJSONKeyFunction [ScalingAdjustmentType]
FromJSONKeyFunction ScalingAdjustmentType
FromJSONKeyFunction ScalingAdjustmentType
-> FromJSONKeyFunction [ScalingAdjustmentType]
-> FromJSONKey ScalingAdjustmentType
forall a.
FromJSONKeyFunction a -> FromJSONKeyFunction [a] -> FromJSONKey a
fromJSONKeyList :: FromJSONKeyFunction [ScalingAdjustmentType]
$cfromJSONKeyList :: FromJSONKeyFunction [ScalingAdjustmentType]
fromJSONKey :: FromJSONKeyFunction ScalingAdjustmentType
$cfromJSONKey :: FromJSONKeyFunction ScalingAdjustmentType
Core.FromJSONKey,
      [ScalingAdjustmentType] -> Encoding
[ScalingAdjustmentType] -> Value
ScalingAdjustmentType -> Encoding
ScalingAdjustmentType -> Value
(ScalingAdjustmentType -> Value)
-> (ScalingAdjustmentType -> Encoding)
-> ([ScalingAdjustmentType] -> Value)
-> ([ScalingAdjustmentType] -> Encoding)
-> ToJSON ScalingAdjustmentType
forall a.
(a -> Value)
-> (a -> Encoding)
-> ([a] -> Value)
-> ([a] -> Encoding)
-> ToJSON a
toEncodingList :: [ScalingAdjustmentType] -> Encoding
$ctoEncodingList :: [ScalingAdjustmentType] -> Encoding
toJSONList :: [ScalingAdjustmentType] -> Value
$ctoJSONList :: [ScalingAdjustmentType] -> Value
toEncoding :: ScalingAdjustmentType -> Encoding
$ctoEncoding :: ScalingAdjustmentType -> Encoding
toJSON :: ScalingAdjustmentType -> Value
$ctoJSON :: ScalingAdjustmentType -> Value
Core.ToJSON,
      ToJSONKeyFunction [ScalingAdjustmentType]
ToJSONKeyFunction ScalingAdjustmentType
ToJSONKeyFunction ScalingAdjustmentType
-> ToJSONKeyFunction [ScalingAdjustmentType]
-> ToJSONKey ScalingAdjustmentType
forall a.
ToJSONKeyFunction a -> ToJSONKeyFunction [a] -> ToJSONKey a
toJSONKeyList :: ToJSONKeyFunction [ScalingAdjustmentType]
$ctoJSONKeyList :: ToJSONKeyFunction [ScalingAdjustmentType]
toJSONKey :: ToJSONKeyFunction ScalingAdjustmentType
$ctoJSONKey :: ToJSONKeyFunction ScalingAdjustmentType
Core.ToJSONKey,
      [Node] -> Either String ScalingAdjustmentType
([Node] -> Either String ScalingAdjustmentType)
-> FromXML ScalingAdjustmentType
forall a. ([Node] -> Either String a) -> FromXML a
parseXML :: [Node] -> Either String ScalingAdjustmentType
$cparseXML :: [Node] -> Either String ScalingAdjustmentType
Core.FromXML,
      ScalingAdjustmentType -> XML
(ScalingAdjustmentType -> XML) -> ToXML ScalingAdjustmentType
forall a. (a -> XML) -> ToXML a
toXML :: ScalingAdjustmentType -> XML
$ctoXML :: ScalingAdjustmentType -> XML
Core.ToXML
    )

pattern ScalingAdjustmentType_ChangeInCapacity :: ScalingAdjustmentType
pattern $bScalingAdjustmentType_ChangeInCapacity :: ScalingAdjustmentType
$mScalingAdjustmentType_ChangeInCapacity :: forall r.
ScalingAdjustmentType -> (Void# -> r) -> (Void# -> r) -> r
ScalingAdjustmentType_ChangeInCapacity = ScalingAdjustmentType' "ChangeInCapacity"

pattern ScalingAdjustmentType_ExactCapacity :: ScalingAdjustmentType
pattern $bScalingAdjustmentType_ExactCapacity :: ScalingAdjustmentType
$mScalingAdjustmentType_ExactCapacity :: forall r.
ScalingAdjustmentType -> (Void# -> r) -> (Void# -> r) -> r
ScalingAdjustmentType_ExactCapacity = ScalingAdjustmentType' "ExactCapacity"

pattern ScalingAdjustmentType_PercentChangeInCapacity :: ScalingAdjustmentType
pattern $bScalingAdjustmentType_PercentChangeInCapacity :: ScalingAdjustmentType
$mScalingAdjustmentType_PercentChangeInCapacity :: forall r.
ScalingAdjustmentType -> (Void# -> r) -> (Void# -> r) -> r
ScalingAdjustmentType_PercentChangeInCapacity = ScalingAdjustmentType' "PercentChangeInCapacity"

{-# COMPLETE
  ScalingAdjustmentType_ChangeInCapacity,
  ScalingAdjustmentType_ExactCapacity,
  ScalingAdjustmentType_PercentChangeInCapacity,
  ScalingAdjustmentType'
  #-}