{-# 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.DeviceFarm.Types.DevicePlatform
-- 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.DeviceFarm.Types.DevicePlatform
  ( DevicePlatform
      ( ..,
        DevicePlatform_ANDROID,
        DevicePlatform_IOS
      ),
  )
where

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

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

pattern DevicePlatform_ANDROID :: DevicePlatform
pattern $bDevicePlatform_ANDROID :: DevicePlatform
$mDevicePlatform_ANDROID :: forall r. DevicePlatform -> (Void# -> r) -> (Void# -> r) -> r
DevicePlatform_ANDROID = DevicePlatform' "ANDROID"

pattern DevicePlatform_IOS :: DevicePlatform
pattern $bDevicePlatform_IOS :: DevicePlatform
$mDevicePlatform_IOS :: forall r. DevicePlatform -> (Void# -> r) -> (Void# -> r) -> r
DevicePlatform_IOS = DevicePlatform' "IOS"

{-# COMPLETE
  DevicePlatform_ANDROID,
  DevicePlatform_IOS,
  DevicePlatform'
  #-}