{-# 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.DirectoryService.Types.TrustDirection
-- 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.DirectoryService.Types.TrustDirection
  ( TrustDirection
      ( ..,
        TrustDirection_One_Way__Incoming,
        TrustDirection_One_Way__Outgoing,
        TrustDirection_Two_Way
      ),
  )
where

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

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

pattern TrustDirection_One_Way__Incoming :: TrustDirection
pattern $bTrustDirection_One_Way__Incoming :: TrustDirection
$mTrustDirection_One_Way__Incoming :: forall {r}. TrustDirection -> ((# #) -> r) -> ((# #) -> r) -> r
TrustDirection_One_Way__Incoming = TrustDirection' "One-Way: Incoming"

pattern TrustDirection_One_Way__Outgoing :: TrustDirection
pattern $bTrustDirection_One_Way__Outgoing :: TrustDirection
$mTrustDirection_One_Way__Outgoing :: forall {r}. TrustDirection -> ((# #) -> r) -> ((# #) -> r) -> r
TrustDirection_One_Way__Outgoing = TrustDirection' "One-Way: Outgoing"

pattern TrustDirection_Two_Way :: TrustDirection
pattern $bTrustDirection_Two_Way :: TrustDirection
$mTrustDirection_Two_Way :: forall {r}. TrustDirection -> ((# #) -> r) -> ((# #) -> r) -> r
TrustDirection_Two_Way = TrustDirection' "Two-Way"

{-# COMPLETE
  TrustDirection_One_Way__Incoming,
  TrustDirection_One_Way__Outgoing,
  TrustDirection_Two_Way,
  TrustDirection'
  #-}