{-# 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.ApiGatewayV2.Types.IntegrationType
-- 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.ApiGatewayV2.Types.IntegrationType
  ( IntegrationType
      ( ..,
        IntegrationType_AWS,
        IntegrationType_AWS_PROXY,
        IntegrationType_HTTP,
        IntegrationType_HTTP_PROXY,
        IntegrationType_MOCK
      ),
  )
where

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

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

pattern IntegrationType_AWS :: IntegrationType
pattern $bIntegrationType_AWS :: IntegrationType
$mIntegrationType_AWS :: forall {r}. IntegrationType -> ((# #) -> r) -> ((# #) -> r) -> r
IntegrationType_AWS = IntegrationType' "AWS"

pattern IntegrationType_AWS_PROXY :: IntegrationType
pattern $bIntegrationType_AWS_PROXY :: IntegrationType
$mIntegrationType_AWS_PROXY :: forall {r}. IntegrationType -> ((# #) -> r) -> ((# #) -> r) -> r
IntegrationType_AWS_PROXY = IntegrationType' "AWS_PROXY"

pattern IntegrationType_HTTP :: IntegrationType
pattern $bIntegrationType_HTTP :: IntegrationType
$mIntegrationType_HTTP :: forall {r}. IntegrationType -> ((# #) -> r) -> ((# #) -> r) -> r
IntegrationType_HTTP = IntegrationType' "HTTP"

pattern IntegrationType_HTTP_PROXY :: IntegrationType
pattern $bIntegrationType_HTTP_PROXY :: IntegrationType
$mIntegrationType_HTTP_PROXY :: forall {r}. IntegrationType -> ((# #) -> r) -> ((# #) -> r) -> r
IntegrationType_HTTP_PROXY = IntegrationType' "HTTP_PROXY"

pattern IntegrationType_MOCK :: IntegrationType
pattern $bIntegrationType_MOCK :: IntegrationType
$mIntegrationType_MOCK :: forall {r}. IntegrationType -> ((# #) -> r) -> ((# #) -> r) -> r
IntegrationType_MOCK = IntegrationType' "MOCK"

{-# COMPLETE
  IntegrationType_AWS,
  IntegrationType_AWS_PROXY,
  IntegrationType_HTTP,
  IntegrationType_HTTP_PROXY,
  IntegrationType_MOCK,
  IntegrationType'
  #-}