{-# 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.SESV2.Types.MailFromDomainStatus
-- 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.SESV2.Types.MailFromDomainStatus
  ( MailFromDomainStatus
      ( ..,
        MailFromDomainStatus_FAILED,
        MailFromDomainStatus_PENDING,
        MailFromDomainStatus_SUCCESS,
        MailFromDomainStatus_TEMPORARY_FAILURE
      ),
  )
where

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

-- | The status of the MAIL FROM domain. This status can have the following
-- values:
--
-- -   @PENDING@ – Amazon SES hasn\'t started searching for the MX record
--     yet.
--
-- -   @SUCCESS@ – Amazon SES detected the required MX record for the MAIL
--     FROM domain.
--
-- -   @FAILED@ – Amazon SES can\'t find the required MX record, or the
--     record no longer exists.
--
-- -   @TEMPORARY_FAILURE@ – A temporary issue occurred, which prevented
--     Amazon SES from determining the status of the MAIL FROM domain.
newtype MailFromDomainStatus = MailFromDomainStatus'
  { MailFromDomainStatus -> Text
fromMailFromDomainStatus ::
      Core.Text
  }
  deriving stock
    ( Int -> MailFromDomainStatus -> ShowS
[MailFromDomainStatus] -> ShowS
MailFromDomainStatus -> String
(Int -> MailFromDomainStatus -> ShowS)
-> (MailFromDomainStatus -> String)
-> ([MailFromDomainStatus] -> ShowS)
-> Show MailFromDomainStatus
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [MailFromDomainStatus] -> ShowS
$cshowList :: [MailFromDomainStatus] -> ShowS
show :: MailFromDomainStatus -> String
$cshow :: MailFromDomainStatus -> String
showsPrec :: Int -> MailFromDomainStatus -> ShowS
$cshowsPrec :: Int -> MailFromDomainStatus -> ShowS
Prelude.Show,
      ReadPrec [MailFromDomainStatus]
ReadPrec MailFromDomainStatus
Int -> ReadS MailFromDomainStatus
ReadS [MailFromDomainStatus]
(Int -> ReadS MailFromDomainStatus)
-> ReadS [MailFromDomainStatus]
-> ReadPrec MailFromDomainStatus
-> ReadPrec [MailFromDomainStatus]
-> Read MailFromDomainStatus
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [MailFromDomainStatus]
$creadListPrec :: ReadPrec [MailFromDomainStatus]
readPrec :: ReadPrec MailFromDomainStatus
$creadPrec :: ReadPrec MailFromDomainStatus
readList :: ReadS [MailFromDomainStatus]
$creadList :: ReadS [MailFromDomainStatus]
readsPrec :: Int -> ReadS MailFromDomainStatus
$creadsPrec :: Int -> ReadS MailFromDomainStatus
Prelude.Read,
      MailFromDomainStatus -> MailFromDomainStatus -> Bool
(MailFromDomainStatus -> MailFromDomainStatus -> Bool)
-> (MailFromDomainStatus -> MailFromDomainStatus -> Bool)
-> Eq MailFromDomainStatus
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: MailFromDomainStatus -> MailFromDomainStatus -> Bool
$c/= :: MailFromDomainStatus -> MailFromDomainStatus -> Bool
== :: MailFromDomainStatus -> MailFromDomainStatus -> Bool
$c== :: MailFromDomainStatus -> MailFromDomainStatus -> Bool
Prelude.Eq,
      Eq MailFromDomainStatus
Eq MailFromDomainStatus
-> (MailFromDomainStatus -> MailFromDomainStatus -> Ordering)
-> (MailFromDomainStatus -> MailFromDomainStatus -> Bool)
-> (MailFromDomainStatus -> MailFromDomainStatus -> Bool)
-> (MailFromDomainStatus -> MailFromDomainStatus -> Bool)
-> (MailFromDomainStatus -> MailFromDomainStatus -> Bool)
-> (MailFromDomainStatus
    -> MailFromDomainStatus -> MailFromDomainStatus)
-> (MailFromDomainStatus
    -> MailFromDomainStatus -> MailFromDomainStatus)
-> Ord MailFromDomainStatus
MailFromDomainStatus -> MailFromDomainStatus -> Bool
MailFromDomainStatus -> MailFromDomainStatus -> Ordering
MailFromDomainStatus
-> MailFromDomainStatus -> MailFromDomainStatus
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 :: MailFromDomainStatus
-> MailFromDomainStatus -> MailFromDomainStatus
$cmin :: MailFromDomainStatus
-> MailFromDomainStatus -> MailFromDomainStatus
max :: MailFromDomainStatus
-> MailFromDomainStatus -> MailFromDomainStatus
$cmax :: MailFromDomainStatus
-> MailFromDomainStatus -> MailFromDomainStatus
>= :: MailFromDomainStatus -> MailFromDomainStatus -> Bool
$c>= :: MailFromDomainStatus -> MailFromDomainStatus -> Bool
> :: MailFromDomainStatus -> MailFromDomainStatus -> Bool
$c> :: MailFromDomainStatus -> MailFromDomainStatus -> Bool
<= :: MailFromDomainStatus -> MailFromDomainStatus -> Bool
$c<= :: MailFromDomainStatus -> MailFromDomainStatus -> Bool
< :: MailFromDomainStatus -> MailFromDomainStatus -> Bool
$c< :: MailFromDomainStatus -> MailFromDomainStatus -> Bool
compare :: MailFromDomainStatus -> MailFromDomainStatus -> Ordering
$ccompare :: MailFromDomainStatus -> MailFromDomainStatus -> Ordering
$cp1Ord :: Eq MailFromDomainStatus
Prelude.Ord,
      (forall x. MailFromDomainStatus -> Rep MailFromDomainStatus x)
-> (forall x. Rep MailFromDomainStatus x -> MailFromDomainStatus)
-> Generic MailFromDomainStatus
forall x. Rep MailFromDomainStatus x -> MailFromDomainStatus
forall x. MailFromDomainStatus -> Rep MailFromDomainStatus x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep MailFromDomainStatus x -> MailFromDomainStatus
$cfrom :: forall x. MailFromDomainStatus -> Rep MailFromDomainStatus x
Prelude.Generic
    )
  deriving newtype
    ( Int -> MailFromDomainStatus -> Int
MailFromDomainStatus -> Int
(Int -> MailFromDomainStatus -> Int)
-> (MailFromDomainStatus -> Int) -> Hashable MailFromDomainStatus
forall a. (Int -> a -> Int) -> (a -> Int) -> Hashable a
hash :: MailFromDomainStatus -> Int
$chash :: MailFromDomainStatus -> Int
hashWithSalt :: Int -> MailFromDomainStatus -> Int
$chashWithSalt :: Int -> MailFromDomainStatus -> Int
Prelude.Hashable,
      MailFromDomainStatus -> ()
(MailFromDomainStatus -> ()) -> NFData MailFromDomainStatus
forall a. (a -> ()) -> NFData a
rnf :: MailFromDomainStatus -> ()
$crnf :: MailFromDomainStatus -> ()
Prelude.NFData,
      Text -> Either String MailFromDomainStatus
(Text -> Either String MailFromDomainStatus)
-> FromText MailFromDomainStatus
forall a. (Text -> Either String a) -> FromText a
fromText :: Text -> Either String MailFromDomainStatus
$cfromText :: Text -> Either String MailFromDomainStatus
Core.FromText,
      MailFromDomainStatus -> Text
(MailFromDomainStatus -> Text) -> ToText MailFromDomainStatus
forall a. (a -> Text) -> ToText a
toText :: MailFromDomainStatus -> Text
$ctoText :: MailFromDomainStatus -> Text
Core.ToText,
      MailFromDomainStatus -> ByteString
(MailFromDomainStatus -> ByteString)
-> ToByteString MailFromDomainStatus
forall a. (a -> ByteString) -> ToByteString a
toBS :: MailFromDomainStatus -> ByteString
$ctoBS :: MailFromDomainStatus -> ByteString
Core.ToByteString,
      MailFromDomainStatus -> ByteStringBuilder
(MailFromDomainStatus -> ByteStringBuilder)
-> ToLog MailFromDomainStatus
forall a. (a -> ByteStringBuilder) -> ToLog a
build :: MailFromDomainStatus -> ByteStringBuilder
$cbuild :: MailFromDomainStatus -> ByteStringBuilder
Core.ToLog,
      HeaderName -> MailFromDomainStatus -> [Header]
(HeaderName -> MailFromDomainStatus -> [Header])
-> ToHeader MailFromDomainStatus
forall a. (HeaderName -> a -> [Header]) -> ToHeader a
toHeader :: HeaderName -> MailFromDomainStatus -> [Header]
$ctoHeader :: HeaderName -> MailFromDomainStatus -> [Header]
Core.ToHeader,
      MailFromDomainStatus -> QueryString
(MailFromDomainStatus -> QueryString)
-> ToQuery MailFromDomainStatus
forall a. (a -> QueryString) -> ToQuery a
toQuery :: MailFromDomainStatus -> QueryString
$ctoQuery :: MailFromDomainStatus -> QueryString
Core.ToQuery,
      Value -> Parser [MailFromDomainStatus]
Value -> Parser MailFromDomainStatus
(Value -> Parser MailFromDomainStatus)
-> (Value -> Parser [MailFromDomainStatus])
-> FromJSON MailFromDomainStatus
forall a.
(Value -> Parser a) -> (Value -> Parser [a]) -> FromJSON a
parseJSONList :: Value -> Parser [MailFromDomainStatus]
$cparseJSONList :: Value -> Parser [MailFromDomainStatus]
parseJSON :: Value -> Parser MailFromDomainStatus
$cparseJSON :: Value -> Parser MailFromDomainStatus
Core.FromJSON,
      FromJSONKeyFunction [MailFromDomainStatus]
FromJSONKeyFunction MailFromDomainStatus
FromJSONKeyFunction MailFromDomainStatus
-> FromJSONKeyFunction [MailFromDomainStatus]
-> FromJSONKey MailFromDomainStatus
forall a.
FromJSONKeyFunction a -> FromJSONKeyFunction [a] -> FromJSONKey a
fromJSONKeyList :: FromJSONKeyFunction [MailFromDomainStatus]
$cfromJSONKeyList :: FromJSONKeyFunction [MailFromDomainStatus]
fromJSONKey :: FromJSONKeyFunction MailFromDomainStatus
$cfromJSONKey :: FromJSONKeyFunction MailFromDomainStatus
Core.FromJSONKey,
      [MailFromDomainStatus] -> Encoding
[MailFromDomainStatus] -> Value
MailFromDomainStatus -> Encoding
MailFromDomainStatus -> Value
(MailFromDomainStatus -> Value)
-> (MailFromDomainStatus -> Encoding)
-> ([MailFromDomainStatus] -> Value)
-> ([MailFromDomainStatus] -> Encoding)
-> ToJSON MailFromDomainStatus
forall a.
(a -> Value)
-> (a -> Encoding)
-> ([a] -> Value)
-> ([a] -> Encoding)
-> ToJSON a
toEncodingList :: [MailFromDomainStatus] -> Encoding
$ctoEncodingList :: [MailFromDomainStatus] -> Encoding
toJSONList :: [MailFromDomainStatus] -> Value
$ctoJSONList :: [MailFromDomainStatus] -> Value
toEncoding :: MailFromDomainStatus -> Encoding
$ctoEncoding :: MailFromDomainStatus -> Encoding
toJSON :: MailFromDomainStatus -> Value
$ctoJSON :: MailFromDomainStatus -> Value
Core.ToJSON,
      ToJSONKeyFunction [MailFromDomainStatus]
ToJSONKeyFunction MailFromDomainStatus
ToJSONKeyFunction MailFromDomainStatus
-> ToJSONKeyFunction [MailFromDomainStatus]
-> ToJSONKey MailFromDomainStatus
forall a.
ToJSONKeyFunction a -> ToJSONKeyFunction [a] -> ToJSONKey a
toJSONKeyList :: ToJSONKeyFunction [MailFromDomainStatus]
$ctoJSONKeyList :: ToJSONKeyFunction [MailFromDomainStatus]
toJSONKey :: ToJSONKeyFunction MailFromDomainStatus
$ctoJSONKey :: ToJSONKeyFunction MailFromDomainStatus
Core.ToJSONKey,
      [Node] -> Either String MailFromDomainStatus
([Node] -> Either String MailFromDomainStatus)
-> FromXML MailFromDomainStatus
forall a. ([Node] -> Either String a) -> FromXML a
parseXML :: [Node] -> Either String MailFromDomainStatus
$cparseXML :: [Node] -> Either String MailFromDomainStatus
Core.FromXML,
      MailFromDomainStatus -> XML
(MailFromDomainStatus -> XML) -> ToXML MailFromDomainStatus
forall a. (a -> XML) -> ToXML a
toXML :: MailFromDomainStatus -> XML
$ctoXML :: MailFromDomainStatus -> XML
Core.ToXML
    )

pattern MailFromDomainStatus_FAILED :: MailFromDomainStatus
pattern $bMailFromDomainStatus_FAILED :: MailFromDomainStatus
$mMailFromDomainStatus_FAILED :: forall r. MailFromDomainStatus -> (Void# -> r) -> (Void# -> r) -> r
MailFromDomainStatus_FAILED = MailFromDomainStatus' "FAILED"

pattern MailFromDomainStatus_PENDING :: MailFromDomainStatus
pattern $bMailFromDomainStatus_PENDING :: MailFromDomainStatus
$mMailFromDomainStatus_PENDING :: forall r. MailFromDomainStatus -> (Void# -> r) -> (Void# -> r) -> r
MailFromDomainStatus_PENDING = MailFromDomainStatus' "PENDING"

pattern MailFromDomainStatus_SUCCESS :: MailFromDomainStatus
pattern $bMailFromDomainStatus_SUCCESS :: MailFromDomainStatus
$mMailFromDomainStatus_SUCCESS :: forall r. MailFromDomainStatus -> (Void# -> r) -> (Void# -> r) -> r
MailFromDomainStatus_SUCCESS = MailFromDomainStatus' "SUCCESS"

pattern MailFromDomainStatus_TEMPORARY_FAILURE :: MailFromDomainStatus
pattern $bMailFromDomainStatus_TEMPORARY_FAILURE :: MailFromDomainStatus
$mMailFromDomainStatus_TEMPORARY_FAILURE :: forall r. MailFromDomainStatus -> (Void# -> r) -> (Void# -> r) -> r
MailFromDomainStatus_TEMPORARY_FAILURE = MailFromDomainStatus' "TEMPORARY_FAILURE"

{-# COMPLETE
  MailFromDomainStatus_FAILED,
  MailFromDomainStatus_PENDING,
  MailFromDomainStatus_SUCCESS,
  MailFromDomainStatus_TEMPORARY_FAILURE,
  MailFromDomainStatus'
  #-}