{-# 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.SecurityHub.Types.RecordState
-- 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.SecurityHub.Types.RecordState
  ( RecordState
      ( ..,
        RecordState_ACTIVE,
        RecordState_ARCHIVED
      ),
  )
where

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

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

pattern RecordState_ACTIVE :: RecordState
pattern $bRecordState_ACTIVE :: RecordState
$mRecordState_ACTIVE :: forall r. RecordState -> (Void# -> r) -> (Void# -> r) -> r
RecordState_ACTIVE = RecordState' "ACTIVE"

pattern RecordState_ARCHIVED :: RecordState
pattern $bRecordState_ARCHIVED :: RecordState
$mRecordState_ARCHIVED :: forall r. RecordState -> (Void# -> r) -> (Void# -> r) -> r
RecordState_ARCHIVED = RecordState' "ARCHIVED"

{-# COMPLETE
  RecordState_ACTIVE,
  RecordState_ARCHIVED,
  RecordState'
  #-}