{-# 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.ChildType
-- 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.Organizations.Types.ChildType
  ( ChildType
      ( ..,
        ChildType_ACCOUNT,
        ChildType_ORGANIZATIONAL_UNIT
      ),
  )
where

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

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

pattern ChildType_ACCOUNT :: ChildType
pattern $bChildType_ACCOUNT :: ChildType
$mChildType_ACCOUNT :: forall {r}. ChildType -> ((# #) -> r) -> ((# #) -> r) -> r
ChildType_ACCOUNT = ChildType' "ACCOUNT"

pattern ChildType_ORGANIZATIONAL_UNIT :: ChildType
pattern $bChildType_ORGANIZATIONAL_UNIT :: ChildType
$mChildType_ORGANIZATIONAL_UNIT :: forall {r}. ChildType -> ((# #) -> r) -> ((# #) -> r) -> r
ChildType_ORGANIZATIONAL_UNIT = ChildType' "ORGANIZATIONAL_UNIT"

{-# COMPLETE
  ChildType_ACCOUNT,
  ChildType_ORGANIZATIONAL_UNIT,
  ChildType'
  #-}