{-# 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.CloudFormation.Types.ResourceAttribute
-- 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.CloudFormation.Types.ResourceAttribute
  ( ResourceAttribute
      ( ..,
        ResourceAttribute_CreationPolicy,
        ResourceAttribute_DeletionPolicy,
        ResourceAttribute_Metadata,
        ResourceAttribute_Properties,
        ResourceAttribute_Tags,
        ResourceAttribute_UpdatePolicy
      ),
  )
where

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

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

pattern ResourceAttribute_CreationPolicy :: ResourceAttribute
pattern $bResourceAttribute_CreationPolicy :: ResourceAttribute
$mResourceAttribute_CreationPolicy :: forall r. ResourceAttribute -> (Void# -> r) -> (Void# -> r) -> r
ResourceAttribute_CreationPolicy = ResourceAttribute' "CreationPolicy"

pattern ResourceAttribute_DeletionPolicy :: ResourceAttribute
pattern $bResourceAttribute_DeletionPolicy :: ResourceAttribute
$mResourceAttribute_DeletionPolicy :: forall r. ResourceAttribute -> (Void# -> r) -> (Void# -> r) -> r
ResourceAttribute_DeletionPolicy = ResourceAttribute' "DeletionPolicy"

pattern ResourceAttribute_Metadata :: ResourceAttribute
pattern $bResourceAttribute_Metadata :: ResourceAttribute
$mResourceAttribute_Metadata :: forall r. ResourceAttribute -> (Void# -> r) -> (Void# -> r) -> r
ResourceAttribute_Metadata = ResourceAttribute' "Metadata"

pattern ResourceAttribute_Properties :: ResourceAttribute
pattern $bResourceAttribute_Properties :: ResourceAttribute
$mResourceAttribute_Properties :: forall r. ResourceAttribute -> (Void# -> r) -> (Void# -> r) -> r
ResourceAttribute_Properties = ResourceAttribute' "Properties"

pattern ResourceAttribute_Tags :: ResourceAttribute
pattern $bResourceAttribute_Tags :: ResourceAttribute
$mResourceAttribute_Tags :: forall r. ResourceAttribute -> (Void# -> r) -> (Void# -> r) -> r
ResourceAttribute_Tags = ResourceAttribute' "Tags"

pattern ResourceAttribute_UpdatePolicy :: ResourceAttribute
pattern $bResourceAttribute_UpdatePolicy :: ResourceAttribute
$mResourceAttribute_UpdatePolicy :: forall r. ResourceAttribute -> (Void# -> r) -> (Void# -> r) -> r
ResourceAttribute_UpdatePolicy = ResourceAttribute' "UpdatePolicy"

{-# COMPLETE
  ResourceAttribute_CreationPolicy,
  ResourceAttribute_DeletionPolicy,
  ResourceAttribute_Metadata,
  ResourceAttribute_Properties,
  ResourceAttribute_Tags,
  ResourceAttribute_UpdatePolicy,
  ResourceAttribute'
  #-}