{-# 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.EC2.Types.MarketType
-- 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.EC2.Types.MarketType
  ( MarketType
      ( ..,
        MarketType_Spot
      ),
  )
where

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

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

pattern MarketType_Spot :: MarketType
pattern $bMarketType_Spot :: MarketType
$mMarketType_Spot :: forall {r}. MarketType -> ((# #) -> r) -> ((# #) -> r) -> r
MarketType_Spot = MarketType' "spot"

{-# COMPLETE
  MarketType_Spot,
  MarketType'
  #-}