{-# 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.CloudFormation.Types.DifferenceType
-- 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.CloudFormation.Types.DifferenceType
  ( DifferenceType
      ( ..,
        DifferenceType_ADD,
        DifferenceType_NOT_EQUAL,
        DifferenceType_REMOVE
      ),
  )
where

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

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

pattern DifferenceType_ADD :: DifferenceType
pattern $bDifferenceType_ADD :: DifferenceType
$mDifferenceType_ADD :: forall r. DifferenceType -> (Void# -> r) -> (Void# -> r) -> r
DifferenceType_ADD = DifferenceType' "ADD"

pattern DifferenceType_NOT_EQUAL :: DifferenceType
pattern $bDifferenceType_NOT_EQUAL :: DifferenceType
$mDifferenceType_NOT_EQUAL :: forall r. DifferenceType -> (Void# -> r) -> (Void# -> r) -> r
DifferenceType_NOT_EQUAL = DifferenceType' "NOT_EQUAL"

pattern DifferenceType_REMOVE :: DifferenceType
pattern $bDifferenceType_REMOVE :: DifferenceType
$mDifferenceType_REMOVE :: forall r. DifferenceType -> (Void# -> r) -> (Void# -> r) -> r
DifferenceType_REMOVE = DifferenceType' "REMOVE"

{-# COMPLETE
  DifferenceType_ADD,
  DifferenceType_NOT_EQUAL,
  DifferenceType_REMOVE,
  DifferenceType'
  #-}