{-# 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.SSM.Types.PatchAction
-- 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.SSM.Types.PatchAction
  ( PatchAction
      ( ..,
        PatchAction_ALLOW_AS_DEPENDENCY,
        PatchAction_BLOCK
      ),
  )
where

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

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

pattern PatchAction_ALLOW_AS_DEPENDENCY :: PatchAction
pattern $bPatchAction_ALLOW_AS_DEPENDENCY :: PatchAction
$mPatchAction_ALLOW_AS_DEPENDENCY :: forall r. PatchAction -> (Void# -> r) -> (Void# -> r) -> r
PatchAction_ALLOW_AS_DEPENDENCY = PatchAction' "ALLOW_AS_DEPENDENCY"

pattern PatchAction_BLOCK :: PatchAction
pattern $bPatchAction_BLOCK :: PatchAction
$mPatchAction_BLOCK :: forall r. PatchAction -> (Void# -> r) -> (Void# -> r) -> r
PatchAction_BLOCK = PatchAction' "BLOCK"

{-# COMPLETE
  PatchAction_ALLOW_AS_DEPENDENCY,
  PatchAction_BLOCK,
  PatchAction'
  #-}