{-# 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.CostExplorer.Types.GroupDefinitionType
-- 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.CostExplorer.Types.GroupDefinitionType
  ( GroupDefinitionType
      ( ..,
        GroupDefinitionType_COST_CATEGORY,
        GroupDefinitionType_DIMENSION,
        GroupDefinitionType_TAG
      ),
  )
where

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

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

pattern GroupDefinitionType_COST_CATEGORY :: GroupDefinitionType
pattern $bGroupDefinitionType_COST_CATEGORY :: GroupDefinitionType
$mGroupDefinitionType_COST_CATEGORY :: forall r. GroupDefinitionType -> (Void# -> r) -> (Void# -> r) -> r
GroupDefinitionType_COST_CATEGORY = GroupDefinitionType' "COST_CATEGORY"

pattern GroupDefinitionType_DIMENSION :: GroupDefinitionType
pattern $bGroupDefinitionType_DIMENSION :: GroupDefinitionType
$mGroupDefinitionType_DIMENSION :: forall r. GroupDefinitionType -> (Void# -> r) -> (Void# -> r) -> r
GroupDefinitionType_DIMENSION = GroupDefinitionType' "DIMENSION"

pattern GroupDefinitionType_TAG :: GroupDefinitionType
pattern $bGroupDefinitionType_TAG :: GroupDefinitionType
$mGroupDefinitionType_TAG :: forall r. GroupDefinitionType -> (Void# -> r) -> (Void# -> r) -> r
GroupDefinitionType_TAG = GroupDefinitionType' "TAG"

{-# COMPLETE
  GroupDefinitionType_COST_CATEGORY,
  GroupDefinitionType_DIMENSION,
  GroupDefinitionType_TAG,
  GroupDefinitionType'
  #-}