{-# 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.AppSync.Types.DefaultAction
-- 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.AppSync.Types.DefaultAction
  ( DefaultAction
      ( ..,
        DefaultAction_ALLOW,
        DefaultAction_DENY
      ),
  )
where

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

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

pattern DefaultAction_ALLOW :: DefaultAction
pattern $bDefaultAction_ALLOW :: DefaultAction
$mDefaultAction_ALLOW :: forall {r}. DefaultAction -> ((# #) -> r) -> ((# #) -> r) -> r
DefaultAction_ALLOW = DefaultAction' "ALLOW"

pattern DefaultAction_DENY :: DefaultAction
pattern $bDefaultAction_DENY :: DefaultAction
$mDefaultAction_DENY :: forall {r}. DefaultAction -> ((# #) -> r) -> ((# #) -> r) -> r
DefaultAction_DENY = DefaultAction' "DENY"

{-# COMPLETE
  DefaultAction_ALLOW,
  DefaultAction_DENY,
  DefaultAction'
  #-}