{-# 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.LookoutMetrics.Types.SnsFormat
-- Copyright   : (c) 2013-2023 Brendan Hay
-- License     : Mozilla Public License, v. 2.0.
-- Maintainer  : Brendan Hay
-- Stability   : auto-generated
-- Portability : non-portable (GHC extensions)
module Amazonka.LookoutMetrics.Types.SnsFormat
  ( SnsFormat
      ( ..,
        SnsFormat_JSON,
        SnsFormat_LONG_TEXT,
        SnsFormat_SHORT_TEXT
      ),
  )
where

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

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

pattern SnsFormat_JSON :: SnsFormat
pattern $bSnsFormat_JSON :: SnsFormat
$mSnsFormat_JSON :: forall {r}. SnsFormat -> ((# #) -> r) -> ((# #) -> r) -> r
SnsFormat_JSON = SnsFormat' "JSON"

pattern SnsFormat_LONG_TEXT :: SnsFormat
pattern $bSnsFormat_LONG_TEXT :: SnsFormat
$mSnsFormat_LONG_TEXT :: forall {r}. SnsFormat -> ((# #) -> r) -> ((# #) -> r) -> r
SnsFormat_LONG_TEXT = SnsFormat' "LONG_TEXT"

pattern SnsFormat_SHORT_TEXT :: SnsFormat
pattern $bSnsFormat_SHORT_TEXT :: SnsFormat
$mSnsFormat_SHORT_TEXT :: forall {r}. SnsFormat -> ((# #) -> r) -> ((# #) -> r) -> r
SnsFormat_SHORT_TEXT = SnsFormat' "SHORT_TEXT"

{-# COMPLETE
  SnsFormat_JSON,
  SnsFormat_LONG_TEXT,
  SnsFormat_SHORT_TEXT,
  SnsFormat'
  #-}