{-# 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.DataSync.Types.PreserveDevices
-- 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.DataSync.Types.PreserveDevices
  ( PreserveDevices
      ( ..,
        PreserveDevices_NONE,
        PreserveDevices_PRESERVE
      ),
  )
where

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

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

pattern PreserveDevices_NONE :: PreserveDevices
pattern $bPreserveDevices_NONE :: PreserveDevices
$mPreserveDevices_NONE :: forall r. PreserveDevices -> (Void# -> r) -> (Void# -> r) -> r
PreserveDevices_NONE = PreserveDevices' "NONE"

pattern PreserveDevices_PRESERVE :: PreserveDevices
pattern $bPreserveDevices_PRESERVE :: PreserveDevices
$mPreserveDevices_PRESERVE :: forall r. PreserveDevices -> (Void# -> r) -> (Void# -> r) -> r
PreserveDevices_PRESERVE = PreserveDevices' "PRESERVE"

{-# COMPLETE
  PreserveDevices_NONE,
  PreserveDevices_PRESERVE,
  PreserveDevices'
  #-}