{- ORMOLU_DISABLE -}
{- HLINT ignore -}
-- THIS IS A GENERATED FILE, DO NOT EDIT

{-# OPTIONS_GHC -Wno-unused-imports #-}
{-# OPTIONS_GHC -Wno-unused-matches #-}
{-# OPTIONS_GHC -Wno-deprecations #-}
module Language.LSP.Protocol.Internal.Types.ResourceOperationKind where

import Control.DeepSeq
import Data.Hashable
import GHC.Generics
import Language.LSP.Protocol.Utils.Misc
import Prettyprinter
import qualified Data.Aeson as Aeson
import qualified Data.Row.Aeson as Aeson
import qualified Data.Row.Hashable as Hashable
import qualified Data.Set
import qualified Data.String
import qualified Data.Text
import qualified Language.LSP.Protocol.Types.LspEnum

{-|

-}
data ResourceOperationKind = 
    {-|
  Supports creating new files and folders.
  -}
  ResourceOperationKind_Create
  | {-|
  Supports renaming existing files and folders.
  -}
  ResourceOperationKind_Rename
  | {-|
  Supports deleting existing files and folders.
  -}
  ResourceOperationKind_Delete
  deriving stock (Int -> ResourceOperationKind -> ShowS
[ResourceOperationKind] -> ShowS
ResourceOperationKind -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [ResourceOperationKind] -> ShowS
$cshowList :: [ResourceOperationKind] -> ShowS
show :: ResourceOperationKind -> String
$cshow :: ResourceOperationKind -> String
showsPrec :: Int -> ResourceOperationKind -> ShowS
$cshowsPrec :: Int -> ResourceOperationKind -> ShowS
Show, ResourceOperationKind -> ResourceOperationKind -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: ResourceOperationKind -> ResourceOperationKind -> Bool
$c/= :: ResourceOperationKind -> ResourceOperationKind -> Bool
== :: ResourceOperationKind -> ResourceOperationKind -> Bool
$c== :: ResourceOperationKind -> ResourceOperationKind -> Bool
Eq, Eq ResourceOperationKind
ResourceOperationKind -> ResourceOperationKind -> Bool
ResourceOperationKind -> ResourceOperationKind -> Ordering
ResourceOperationKind
-> ResourceOperationKind -> ResourceOperationKind
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 :: ResourceOperationKind
-> ResourceOperationKind -> ResourceOperationKind
$cmin :: ResourceOperationKind
-> ResourceOperationKind -> ResourceOperationKind
max :: ResourceOperationKind
-> ResourceOperationKind -> ResourceOperationKind
$cmax :: ResourceOperationKind
-> ResourceOperationKind -> ResourceOperationKind
>= :: ResourceOperationKind -> ResourceOperationKind -> Bool
$c>= :: ResourceOperationKind -> ResourceOperationKind -> Bool
> :: ResourceOperationKind -> ResourceOperationKind -> Bool
$c> :: ResourceOperationKind -> ResourceOperationKind -> Bool
<= :: ResourceOperationKind -> ResourceOperationKind -> Bool
$c<= :: ResourceOperationKind -> ResourceOperationKind -> Bool
< :: ResourceOperationKind -> ResourceOperationKind -> Bool
$c< :: ResourceOperationKind -> ResourceOperationKind -> Bool
compare :: ResourceOperationKind -> ResourceOperationKind -> Ordering
$ccompare :: ResourceOperationKind -> ResourceOperationKind -> Ordering
Ord, forall x. Rep ResourceOperationKind x -> ResourceOperationKind
forall x. ResourceOperationKind -> Rep ResourceOperationKind x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep ResourceOperationKind x -> ResourceOperationKind
$cfrom :: forall x. ResourceOperationKind -> Rep ResourceOperationKind x
Generic)
  deriving anyclass (ResourceOperationKind -> ()
forall a. (a -> ()) -> NFData a
rnf :: ResourceOperationKind -> ()
$crnf :: ResourceOperationKind -> ()
NFData, Eq ResourceOperationKind
Int -> ResourceOperationKind -> Int
ResourceOperationKind -> Int
forall a. Eq a -> (Int -> a -> Int) -> (a -> Int) -> Hashable a
hash :: ResourceOperationKind -> Int
$chash :: ResourceOperationKind -> Int
hashWithSalt :: Int -> ResourceOperationKind -> Int
$chashWithSalt :: Int -> ResourceOperationKind -> Int
Hashable)
  deriving ( [ResourceOperationKind] -> Encoding
[ResourceOperationKind] -> Value
ResourceOperationKind -> Encoding
ResourceOperationKind -> Value
forall a.
(a -> Value)
-> (a -> Encoding)
-> ([a] -> Value)
-> ([a] -> Encoding)
-> ToJSON a
toEncodingList :: [ResourceOperationKind] -> Encoding
$ctoEncodingList :: [ResourceOperationKind] -> Encoding
toJSONList :: [ResourceOperationKind] -> Value
$ctoJSONList :: [ResourceOperationKind] -> Value
toEncoding :: ResourceOperationKind -> Encoding
$ctoEncoding :: ResourceOperationKind -> Encoding
toJSON :: ResourceOperationKind -> Value
$ctoJSON :: ResourceOperationKind -> Value
Aeson.ToJSON
  , Value -> Parser [ResourceOperationKind]
Value -> Parser ResourceOperationKind
forall a.
(Value -> Parser a) -> (Value -> Parser [a]) -> FromJSON a
parseJSONList :: Value -> Parser [ResourceOperationKind]
$cparseJSONList :: Value -> Parser [ResourceOperationKind]
parseJSON :: Value -> Parser ResourceOperationKind
$cparseJSON :: Value -> Parser ResourceOperationKind
Aeson.FromJSON ) via (Language.LSP.Protocol.Types.LspEnum.AsLspEnum ResourceOperationKind Data.Text.Text)
  deriving forall ann. [ResourceOperationKind] -> Doc ann
forall ann. ResourceOperationKind -> Doc ann
forall a.
(forall ann. a -> Doc ann)
-> (forall ann. [a] -> Doc ann) -> Pretty a
prettyList :: forall ann. [ResourceOperationKind] -> Doc ann
$cprettyList :: forall ann. [ResourceOperationKind] -> Doc ann
pretty :: forall ann. ResourceOperationKind -> Doc ann
$cpretty :: forall ann. ResourceOperationKind -> Doc ann
Pretty via (ViaJSON ResourceOperationKind)

instance Language.LSP.Protocol.Types.LspEnum.LspEnum ResourceOperationKind where
  knownValues :: Set ResourceOperationKind
knownValues = forall a. Ord a => [a] -> Set a
Data.Set.fromList [ResourceOperationKind
ResourceOperationKind_Create
    ,ResourceOperationKind
ResourceOperationKind_Rename
    ,ResourceOperationKind
ResourceOperationKind_Delete]
  type EnumBaseType ResourceOperationKind = Data.Text.Text
  toEnumBaseType :: ResourceOperationKind -> EnumBaseType ResourceOperationKind
toEnumBaseType ResourceOperationKind
ResourceOperationKind_Create = Text
"create"
  toEnumBaseType ResourceOperationKind
ResourceOperationKind_Rename = Text
"rename"
  toEnumBaseType ResourceOperationKind
ResourceOperationKind_Delete = Text
"delete"
  fromEnumBaseType :: EnumBaseType ResourceOperationKind -> Maybe ResourceOperationKind
fromEnumBaseType EnumBaseType ResourceOperationKind
"create" = forall (f :: * -> *) a. Applicative f => a -> f a
pure ResourceOperationKind
ResourceOperationKind_Create
  fromEnumBaseType EnumBaseType ResourceOperationKind
"rename" = forall (f :: * -> *) a. Applicative f => a -> f a
pure ResourceOperationKind
ResourceOperationKind_Rename
  fromEnumBaseType EnumBaseType ResourceOperationKind
"delete" = forall (f :: * -> *) a. Applicative f => a -> f a
pure ResourceOperationKind
ResourceOperationKind_Delete
  fromEnumBaseType EnumBaseType ResourceOperationKind
_ = forall a. Maybe a
Nothing