{-# 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.QuickSight.Types.ColumnRole
-- 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.QuickSight.Types.ColumnRole
  ( ColumnRole
      ( ..,
        ColumnRole_DIMENSION,
        ColumnRole_MEASURE
      ),
  )
where

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

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

pattern ColumnRole_DIMENSION :: ColumnRole
pattern $bColumnRole_DIMENSION :: ColumnRole
$mColumnRole_DIMENSION :: forall {r}. ColumnRole -> ((# #) -> r) -> ((# #) -> r) -> r
ColumnRole_DIMENSION = ColumnRole' "DIMENSION"

pattern ColumnRole_MEASURE :: ColumnRole
pattern $bColumnRole_MEASURE :: ColumnRole
$mColumnRole_MEASURE :: forall {r}. ColumnRole -> ((# #) -> r) -> ((# #) -> r) -> r
ColumnRole_MEASURE = ColumnRole' "MEASURE"

{-# COMPLETE
  ColumnRole_DIMENSION,
  ColumnRole_MEASURE,
  ColumnRole'
  #-}