{-# 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.Organizations.Types.AccountJoinedMethod
-- 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.Organizations.Types.AccountJoinedMethod
  ( AccountJoinedMethod
      ( ..,
        AccountJoinedMethod_CREATED,
        AccountJoinedMethod_INVITED
      ),
  )
where

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

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

pattern AccountJoinedMethod_CREATED :: AccountJoinedMethod
pattern $bAccountJoinedMethod_CREATED :: AccountJoinedMethod
$mAccountJoinedMethod_CREATED :: forall r. AccountJoinedMethod -> (Void# -> r) -> (Void# -> r) -> r
AccountJoinedMethod_CREATED = AccountJoinedMethod' "CREATED"

pattern AccountJoinedMethod_INVITED :: AccountJoinedMethod
pattern $bAccountJoinedMethod_INVITED :: AccountJoinedMethod
$mAccountJoinedMethod_INVITED :: forall r. AccountJoinedMethod -> (Void# -> r) -> (Void# -> r) -> r
AccountJoinedMethod_INVITED = AccountJoinedMethod' "INVITED"

{-# COMPLETE
  AccountJoinedMethod_CREATED,
  AccountJoinedMethod_INVITED,
  AccountJoinedMethod'
  #-}