{-# 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.MQ.Types.BrokerStorageType
-- 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.MQ.Types.BrokerStorageType
  ( BrokerStorageType
      ( ..,
        BrokerStorageType_EBS,
        BrokerStorageType_EFS
      ),
  )
where

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

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

pattern BrokerStorageType_EBS :: BrokerStorageType
pattern $bBrokerStorageType_EBS :: BrokerStorageType
$mBrokerStorageType_EBS :: forall r. BrokerStorageType -> (Void# -> r) -> (Void# -> r) -> r
BrokerStorageType_EBS = BrokerStorageType' "EBS"

pattern BrokerStorageType_EFS :: BrokerStorageType
pattern $bBrokerStorageType_EFS :: BrokerStorageType
$mBrokerStorageType_EFS :: forall r. BrokerStorageType -> (Void# -> r) -> (Void# -> r) -> r
BrokerStorageType_EFS = BrokerStorageType' "EFS"

{-# COMPLETE
  BrokerStorageType_EBS,
  BrokerStorageType_EFS,
  BrokerStorageType'
  #-}