{-# 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.WorkSpaces.Types.AccessPropertyValue
-- 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.WorkSpaces.Types.AccessPropertyValue
  ( AccessPropertyValue
      ( ..,
        AccessPropertyValue_ALLOW,
        AccessPropertyValue_DENY
      ),
  )
where

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

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

pattern AccessPropertyValue_ALLOW :: AccessPropertyValue
pattern $bAccessPropertyValue_ALLOW :: AccessPropertyValue
$mAccessPropertyValue_ALLOW :: forall {r}.
AccessPropertyValue -> ((# #) -> r) -> ((# #) -> r) -> r
AccessPropertyValue_ALLOW = AccessPropertyValue' "ALLOW"

pattern AccessPropertyValue_DENY :: AccessPropertyValue
pattern $bAccessPropertyValue_DENY :: AccessPropertyValue
$mAccessPropertyValue_DENY :: forall {r}.
AccessPropertyValue -> ((# #) -> r) -> ((# #) -> r) -> r
AccessPropertyValue_DENY = AccessPropertyValue' "DENY"

{-# COMPLETE
  AccessPropertyValue_ALLOW,
  AccessPropertyValue_DENY,
  AccessPropertyValue'
  #-}