{-# 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.EFS.Types.Resource
-- 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.EFS.Types.Resource
  ( Resource
      ( ..,
        Resource_FILE_SYSTEM,
        Resource_MOUNT_TARGET
      ),
  )
where

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

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

pattern Resource_FILE_SYSTEM :: Resource
pattern $bResource_FILE_SYSTEM :: Resource
$mResource_FILE_SYSTEM :: forall r. Resource -> (Void# -> r) -> (Void# -> r) -> r
Resource_FILE_SYSTEM = Resource' "FILE_SYSTEM"

pattern Resource_MOUNT_TARGET :: Resource
pattern $bResource_MOUNT_TARGET :: Resource
$mResource_MOUNT_TARGET :: forall r. Resource -> (Void# -> r) -> (Void# -> r) -> r
Resource_MOUNT_TARGET = Resource' "MOUNT_TARGET"

{-# COMPLETE
  Resource_FILE_SYSTEM,
  Resource_MOUNT_TARGET,
  Resource'
  #-}