{-# 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.MediaConvert.Types.QueueListBy
-- 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.MediaConvert.Types.QueueListBy
  ( QueueListBy
      ( ..,
        QueueListBy_CREATION_DATE,
        QueueListBy_NAME
      ),
  )
where

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

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

pattern QueueListBy_CREATION_DATE :: QueueListBy
pattern $bQueueListBy_CREATION_DATE :: QueueListBy
$mQueueListBy_CREATION_DATE :: forall r. QueueListBy -> (Void# -> r) -> (Void# -> r) -> r
QueueListBy_CREATION_DATE = QueueListBy' "CREATION_DATE"

pattern QueueListBy_NAME :: QueueListBy
pattern $bQueueListBy_NAME :: QueueListBy
$mQueueListBy_NAME :: forall r. QueueListBy -> (Void# -> r) -> (Void# -> r) -> r
QueueListBy_NAME = QueueListBy' "NAME"

{-# COMPLETE
  QueueListBy_CREATION_DATE,
  QueueListBy_NAME,
  QueueListBy'
  #-}