{-# 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.QuickSight.Types.DataSourceErrorInfoType
-- 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.QuickSight.Types.DataSourceErrorInfoType
  ( DataSourceErrorInfoType
      ( ..,
        DataSourceErrorInfoType_ACCESS_DENIED,
        DataSourceErrorInfoType_CONFLICT,
        DataSourceErrorInfoType_COPY_SOURCE_NOT_FOUND,
        DataSourceErrorInfoType_ENGINE_VERSION_NOT_SUPPORTED,
        DataSourceErrorInfoType_GENERIC_SQL_FAILURE,
        DataSourceErrorInfoType_TIMEOUT,
        DataSourceErrorInfoType_UNKNOWN,
        DataSourceErrorInfoType_UNKNOWN_HOST
      ),
  )
where

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

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

pattern DataSourceErrorInfoType_ACCESS_DENIED :: DataSourceErrorInfoType
pattern $bDataSourceErrorInfoType_ACCESS_DENIED :: DataSourceErrorInfoType
$mDataSourceErrorInfoType_ACCESS_DENIED :: forall r.
DataSourceErrorInfoType -> (Void# -> r) -> (Void# -> r) -> r
DataSourceErrorInfoType_ACCESS_DENIED = DataSourceErrorInfoType' "ACCESS_DENIED"

pattern DataSourceErrorInfoType_CONFLICT :: DataSourceErrorInfoType
pattern $bDataSourceErrorInfoType_CONFLICT :: DataSourceErrorInfoType
$mDataSourceErrorInfoType_CONFLICT :: forall r.
DataSourceErrorInfoType -> (Void# -> r) -> (Void# -> r) -> r
DataSourceErrorInfoType_CONFLICT = DataSourceErrorInfoType' "CONFLICT"

pattern DataSourceErrorInfoType_COPY_SOURCE_NOT_FOUND :: DataSourceErrorInfoType
pattern $bDataSourceErrorInfoType_COPY_SOURCE_NOT_FOUND :: DataSourceErrorInfoType
$mDataSourceErrorInfoType_COPY_SOURCE_NOT_FOUND :: forall r.
DataSourceErrorInfoType -> (Void# -> r) -> (Void# -> r) -> r
DataSourceErrorInfoType_COPY_SOURCE_NOT_FOUND = DataSourceErrorInfoType' "COPY_SOURCE_NOT_FOUND"

pattern DataSourceErrorInfoType_ENGINE_VERSION_NOT_SUPPORTED :: DataSourceErrorInfoType
pattern $bDataSourceErrorInfoType_ENGINE_VERSION_NOT_SUPPORTED :: DataSourceErrorInfoType
$mDataSourceErrorInfoType_ENGINE_VERSION_NOT_SUPPORTED :: forall r.
DataSourceErrorInfoType -> (Void# -> r) -> (Void# -> r) -> r
DataSourceErrorInfoType_ENGINE_VERSION_NOT_SUPPORTED = DataSourceErrorInfoType' "ENGINE_VERSION_NOT_SUPPORTED"

pattern DataSourceErrorInfoType_GENERIC_SQL_FAILURE :: DataSourceErrorInfoType
pattern $bDataSourceErrorInfoType_GENERIC_SQL_FAILURE :: DataSourceErrorInfoType
$mDataSourceErrorInfoType_GENERIC_SQL_FAILURE :: forall r.
DataSourceErrorInfoType -> (Void# -> r) -> (Void# -> r) -> r
DataSourceErrorInfoType_GENERIC_SQL_FAILURE = DataSourceErrorInfoType' "GENERIC_SQL_FAILURE"

pattern DataSourceErrorInfoType_TIMEOUT :: DataSourceErrorInfoType
pattern $bDataSourceErrorInfoType_TIMEOUT :: DataSourceErrorInfoType
$mDataSourceErrorInfoType_TIMEOUT :: forall r.
DataSourceErrorInfoType -> (Void# -> r) -> (Void# -> r) -> r
DataSourceErrorInfoType_TIMEOUT = DataSourceErrorInfoType' "TIMEOUT"

pattern DataSourceErrorInfoType_UNKNOWN :: DataSourceErrorInfoType
pattern $bDataSourceErrorInfoType_UNKNOWN :: DataSourceErrorInfoType
$mDataSourceErrorInfoType_UNKNOWN :: forall r.
DataSourceErrorInfoType -> (Void# -> r) -> (Void# -> r) -> r
DataSourceErrorInfoType_UNKNOWN = DataSourceErrorInfoType' "UNKNOWN"

pattern DataSourceErrorInfoType_UNKNOWN_HOST :: DataSourceErrorInfoType
pattern $bDataSourceErrorInfoType_UNKNOWN_HOST :: DataSourceErrorInfoType
$mDataSourceErrorInfoType_UNKNOWN_HOST :: forall r.
DataSourceErrorInfoType -> (Void# -> r) -> (Void# -> r) -> r
DataSourceErrorInfoType_UNKNOWN_HOST = DataSourceErrorInfoType' "UNKNOWN_HOST"

{-# COMPLETE
  DataSourceErrorInfoType_ACCESS_DENIED,
  DataSourceErrorInfoType_CONFLICT,
  DataSourceErrorInfoType_COPY_SOURCE_NOT_FOUND,
  DataSourceErrorInfoType_ENGINE_VERSION_NOT_SUPPORTED,
  DataSourceErrorInfoType_GENERIC_SQL_FAILURE,
  DataSourceErrorInfoType_TIMEOUT,
  DataSourceErrorInfoType_UNKNOWN,
  DataSourceErrorInfoType_UNKNOWN_HOST,
  DataSourceErrorInfoType'
  #-}