{-# 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.Lightsail.Types.ContainerServiceProtocol
-- 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.Lightsail.Types.ContainerServiceProtocol
  ( ContainerServiceProtocol
      ( ..,
        ContainerServiceProtocol_HTTP,
        ContainerServiceProtocol_HTTPS,
        ContainerServiceProtocol_TCP,
        ContainerServiceProtocol_UDP
      ),
  )
where

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

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

pattern ContainerServiceProtocol_HTTP :: ContainerServiceProtocol
pattern $bContainerServiceProtocol_HTTP :: ContainerServiceProtocol
$mContainerServiceProtocol_HTTP :: forall r.
ContainerServiceProtocol -> (Void# -> r) -> (Void# -> r) -> r
ContainerServiceProtocol_HTTP = ContainerServiceProtocol' "HTTP"

pattern ContainerServiceProtocol_HTTPS :: ContainerServiceProtocol
pattern $bContainerServiceProtocol_HTTPS :: ContainerServiceProtocol
$mContainerServiceProtocol_HTTPS :: forall r.
ContainerServiceProtocol -> (Void# -> r) -> (Void# -> r) -> r
ContainerServiceProtocol_HTTPS = ContainerServiceProtocol' "HTTPS"

pattern ContainerServiceProtocol_TCP :: ContainerServiceProtocol
pattern $bContainerServiceProtocol_TCP :: ContainerServiceProtocol
$mContainerServiceProtocol_TCP :: forall r.
ContainerServiceProtocol -> (Void# -> r) -> (Void# -> r) -> r
ContainerServiceProtocol_TCP = ContainerServiceProtocol' "TCP"

pattern ContainerServiceProtocol_UDP :: ContainerServiceProtocol
pattern $bContainerServiceProtocol_UDP :: ContainerServiceProtocol
$mContainerServiceProtocol_UDP :: forall r.
ContainerServiceProtocol -> (Void# -> r) -> (Void# -> r) -> r
ContainerServiceProtocol_UDP = ContainerServiceProtocol' "UDP"

{-# COMPLETE
  ContainerServiceProtocol_HTTP,
  ContainerServiceProtocol_HTTPS,
  ContainerServiceProtocol_TCP,
  ContainerServiceProtocol_UDP,
  ContainerServiceProtocol'
  #-}