{-# 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.MetricName
-- 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.MetricName
  ( MetricName
      ( ..,
        MetricName_ActivatingGameSessions,
        MetricName_ActiveGameSessions,
        MetricName_ActiveInstances,
        MetricName_AvailableGameSessions,
        MetricName_AvailablePlayerSessions,
        MetricName_CurrentPlayerSessions,
        MetricName_IdleInstances,
        MetricName_PercentAvailableGameSessions,
        MetricName_PercentIdleInstances,
        MetricName_QueueDepth,
        MetricName_WaitTime
      ),
  )
where

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

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

pattern MetricName_ActivatingGameSessions :: MetricName
pattern $bMetricName_ActivatingGameSessions :: MetricName
$mMetricName_ActivatingGameSessions :: forall r. MetricName -> (Void# -> r) -> (Void# -> r) -> r
MetricName_ActivatingGameSessions = MetricName' "ActivatingGameSessions"

pattern MetricName_ActiveGameSessions :: MetricName
pattern $bMetricName_ActiveGameSessions :: MetricName
$mMetricName_ActiveGameSessions :: forall r. MetricName -> (Void# -> r) -> (Void# -> r) -> r
MetricName_ActiveGameSessions = MetricName' "ActiveGameSessions"

pattern MetricName_ActiveInstances :: MetricName
pattern $bMetricName_ActiveInstances :: MetricName
$mMetricName_ActiveInstances :: forall r. MetricName -> (Void# -> r) -> (Void# -> r) -> r
MetricName_ActiveInstances = MetricName' "ActiveInstances"

pattern MetricName_AvailableGameSessions :: MetricName
pattern $bMetricName_AvailableGameSessions :: MetricName
$mMetricName_AvailableGameSessions :: forall r. MetricName -> (Void# -> r) -> (Void# -> r) -> r
MetricName_AvailableGameSessions = MetricName' "AvailableGameSessions"

pattern MetricName_AvailablePlayerSessions :: MetricName
pattern $bMetricName_AvailablePlayerSessions :: MetricName
$mMetricName_AvailablePlayerSessions :: forall r. MetricName -> (Void# -> r) -> (Void# -> r) -> r
MetricName_AvailablePlayerSessions = MetricName' "AvailablePlayerSessions"

pattern MetricName_CurrentPlayerSessions :: MetricName
pattern $bMetricName_CurrentPlayerSessions :: MetricName
$mMetricName_CurrentPlayerSessions :: forall r. MetricName -> (Void# -> r) -> (Void# -> r) -> r
MetricName_CurrentPlayerSessions = MetricName' "CurrentPlayerSessions"

pattern MetricName_IdleInstances :: MetricName
pattern $bMetricName_IdleInstances :: MetricName
$mMetricName_IdleInstances :: forall r. MetricName -> (Void# -> r) -> (Void# -> r) -> r
MetricName_IdleInstances = MetricName' "IdleInstances"

pattern MetricName_PercentAvailableGameSessions :: MetricName
pattern $bMetricName_PercentAvailableGameSessions :: MetricName
$mMetricName_PercentAvailableGameSessions :: forall r. MetricName -> (Void# -> r) -> (Void# -> r) -> r
MetricName_PercentAvailableGameSessions = MetricName' "PercentAvailableGameSessions"

pattern MetricName_PercentIdleInstances :: MetricName
pattern $bMetricName_PercentIdleInstances :: MetricName
$mMetricName_PercentIdleInstances :: forall r. MetricName -> (Void# -> r) -> (Void# -> r) -> r
MetricName_PercentIdleInstances = MetricName' "PercentIdleInstances"

pattern MetricName_QueueDepth :: MetricName
pattern $bMetricName_QueueDepth :: MetricName
$mMetricName_QueueDepth :: forall r. MetricName -> (Void# -> r) -> (Void# -> r) -> r
MetricName_QueueDepth = MetricName' "QueueDepth"

pattern MetricName_WaitTime :: MetricName
pattern $bMetricName_WaitTime :: MetricName
$mMetricName_WaitTime :: forall r. MetricName -> (Void# -> r) -> (Void# -> r) -> r
MetricName_WaitTime = MetricName' "WaitTime"

{-# COMPLETE
  MetricName_ActivatingGameSessions,
  MetricName_ActiveGameSessions,
  MetricName_ActiveInstances,
  MetricName_AvailableGameSessions,
  MetricName_AvailablePlayerSessions,
  MetricName_CurrentPlayerSessions,
  MetricName_IdleInstances,
  MetricName_PercentAvailableGameSessions,
  MetricName_PercentIdleInstances,
  MetricName_QueueDepth,
  MetricName_WaitTime,
  MetricName'
  #-}