{-# 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.ServiceCatalog.Types.ProductViewSortBy
-- 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.ServiceCatalog.Types.ProductViewSortBy
  ( ProductViewSortBy
      ( ..,
        ProductViewSortBy_CreationDate,
        ProductViewSortBy_Title,
        ProductViewSortBy_VersionCount
      ),
  )
where

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

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

pattern ProductViewSortBy_CreationDate :: ProductViewSortBy
pattern $bProductViewSortBy_CreationDate :: ProductViewSortBy
$mProductViewSortBy_CreationDate :: forall {r}. ProductViewSortBy -> ((# #) -> r) -> ((# #) -> r) -> r
ProductViewSortBy_CreationDate = ProductViewSortBy' "CreationDate"

pattern ProductViewSortBy_Title :: ProductViewSortBy
pattern $bProductViewSortBy_Title :: ProductViewSortBy
$mProductViewSortBy_Title :: forall {r}. ProductViewSortBy -> ((# #) -> r) -> ((# #) -> r) -> r
ProductViewSortBy_Title = ProductViewSortBy' "Title"

pattern ProductViewSortBy_VersionCount :: ProductViewSortBy
pattern $bProductViewSortBy_VersionCount :: ProductViewSortBy
$mProductViewSortBy_VersionCount :: forall {r}. ProductViewSortBy -> ((# #) -> r) -> ((# #) -> r) -> r
ProductViewSortBy_VersionCount = ProductViewSortBy' "VersionCount"

{-# COMPLETE
  ProductViewSortBy_CreationDate,
  ProductViewSortBy_Title,
  ProductViewSortBy_VersionCount,
  ProductViewSortBy'
  #-}