{-# 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.EC2.Types.InstanceMetadataProtocolState
-- 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.EC2.Types.InstanceMetadataProtocolState
  ( InstanceMetadataProtocolState
      ( ..,
        InstanceMetadataProtocolState_Disabled,
        InstanceMetadataProtocolState_Enabled
      ),
  )
where

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

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

pattern InstanceMetadataProtocolState_Disabled :: InstanceMetadataProtocolState
pattern $bInstanceMetadataProtocolState_Disabled :: InstanceMetadataProtocolState
$mInstanceMetadataProtocolState_Disabled :: forall {r}.
InstanceMetadataProtocolState -> ((# #) -> r) -> ((# #) -> r) -> r
InstanceMetadataProtocolState_Disabled = InstanceMetadataProtocolState' "disabled"

pattern InstanceMetadataProtocolState_Enabled :: InstanceMetadataProtocolState
pattern $bInstanceMetadataProtocolState_Enabled :: InstanceMetadataProtocolState
$mInstanceMetadataProtocolState_Enabled :: forall {r}.
InstanceMetadataProtocolState -> ((# #) -> r) -> ((# #) -> r) -> r
InstanceMetadataProtocolState_Enabled = InstanceMetadataProtocolState' "enabled"

{-# COMPLETE
  InstanceMetadataProtocolState_Disabled,
  InstanceMetadataProtocolState_Enabled,
  InstanceMetadataProtocolState'
  #-}