{-# 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.IoT.Types.ServerCertificateStatus
-- 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.IoT.Types.ServerCertificateStatus
  ( ServerCertificateStatus
      ( ..,
        ServerCertificateStatus_INVALID,
        ServerCertificateStatus_VALID
      ),
  )
where

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

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

pattern ServerCertificateStatus_INVALID :: ServerCertificateStatus
pattern $bServerCertificateStatus_INVALID :: ServerCertificateStatus
$mServerCertificateStatus_INVALID :: forall r.
ServerCertificateStatus -> (Void# -> r) -> (Void# -> r) -> r
ServerCertificateStatus_INVALID = ServerCertificateStatus' "INVALID"

pattern ServerCertificateStatus_VALID :: ServerCertificateStatus
pattern $bServerCertificateStatus_VALID :: ServerCertificateStatus
$mServerCertificateStatus_VALID :: forall r.
ServerCertificateStatus -> (Void# -> r) -> (Void# -> r) -> r
ServerCertificateStatus_VALID = ServerCertificateStatus' "VALID"

{-# COMPLETE
  ServerCertificateStatus_INVALID,
  ServerCertificateStatus_VALID,
  ServerCertificateStatus'
  #-}