{-# 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.Kendra.Types.QueryResultType
-- 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.Kendra.Types.QueryResultType
  ( QueryResultType
      ( ..,
        QueryResultType_ANSWER,
        QueryResultType_DOCUMENT,
        QueryResultType_QUESTION_ANSWER
      ),
  )
where

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

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

pattern QueryResultType_ANSWER :: QueryResultType
pattern $bQueryResultType_ANSWER :: QueryResultType
$mQueryResultType_ANSWER :: forall {r}. QueryResultType -> ((# #) -> r) -> ((# #) -> r) -> r
QueryResultType_ANSWER = QueryResultType' "ANSWER"

pattern QueryResultType_DOCUMENT :: QueryResultType
pattern $bQueryResultType_DOCUMENT :: QueryResultType
$mQueryResultType_DOCUMENT :: forall {r}. QueryResultType -> ((# #) -> r) -> ((# #) -> r) -> r
QueryResultType_DOCUMENT = QueryResultType' "DOCUMENT"

pattern QueryResultType_QUESTION_ANSWER :: QueryResultType
pattern $bQueryResultType_QUESTION_ANSWER :: QueryResultType
$mQueryResultType_QUESTION_ANSWER :: forall {r}. QueryResultType -> ((# #) -> r) -> ((# #) -> r) -> r
QueryResultType_QUESTION_ANSWER = QueryResultType' "QUESTION_ANSWER"

{-# COMPLETE
  QueryResultType_ANSWER,
  QueryResultType_DOCUMENT,
  QueryResultType_QUESTION_ANSWER,
  QueryResultType'
  #-}