{-# OPTIONS_GHC -Wno-unused-imports #-}
{-# OPTIONS_GHC -Wno-unused-matches #-}
{-# OPTIONS_GHC -Wno-deprecations #-}
module Language.LSP.Protocol.Internal.Types.DocumentSymbolClientCapabilities 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 as Row
import qualified Data.Row.Aeson as Aeson
import qualified Data.Row.Hashable as Hashable
import qualified Language.LSP.Protocol.Internal.Types.SymbolKind
import qualified Language.LSP.Protocol.Internal.Types.SymbolTag
import qualified Language.LSP.Protocol.Types.Common
data DocumentSymbolClientCapabilities = DocumentSymbolClientCapabilities
{
DocumentSymbolClientCapabilities -> Maybe Bool
_dynamicRegistration :: (Maybe Bool)
,
DocumentSymbolClientCapabilities
-> Maybe
(Rec (Extend "valueSet" (Maybe [SymbolKind]) ('R '[]) .+ 'R '[]))
_symbolKind :: (Maybe (Row.Rec ("valueSet" Row..== (Maybe [Language.LSP.Protocol.Internal.Types.SymbolKind.SymbolKind]) Row..+ Row.Empty)))
,
DocumentSymbolClientCapabilities -> Maybe Bool
_hierarchicalDocumentSymbolSupport :: (Maybe Bool)
,
DocumentSymbolClientCapabilities
-> Maybe (Rec (Extend "valueSet" [SymbolTag] ('R '[]) .+ 'R '[]))
_tagSupport :: (Maybe (Row.Rec ("valueSet" Row..== [Language.LSP.Protocol.Internal.Types.SymbolTag.SymbolTag] Row..+ Row.Empty)))
,
DocumentSymbolClientCapabilities -> Maybe Bool
_labelSupport :: (Maybe Bool)
}
deriving stock (Int -> DocumentSymbolClientCapabilities -> ShowS
[DocumentSymbolClientCapabilities] -> ShowS
DocumentSymbolClientCapabilities -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [DocumentSymbolClientCapabilities] -> ShowS
$cshowList :: [DocumentSymbolClientCapabilities] -> ShowS
show :: DocumentSymbolClientCapabilities -> String
$cshow :: DocumentSymbolClientCapabilities -> String
showsPrec :: Int -> DocumentSymbolClientCapabilities -> ShowS
$cshowsPrec :: Int -> DocumentSymbolClientCapabilities -> ShowS
Show, DocumentSymbolClientCapabilities
-> DocumentSymbolClientCapabilities -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: DocumentSymbolClientCapabilities
-> DocumentSymbolClientCapabilities -> Bool
$c/= :: DocumentSymbolClientCapabilities
-> DocumentSymbolClientCapabilities -> Bool
== :: DocumentSymbolClientCapabilities
-> DocumentSymbolClientCapabilities -> Bool
$c== :: DocumentSymbolClientCapabilities
-> DocumentSymbolClientCapabilities -> Bool
Eq, Eq DocumentSymbolClientCapabilities
DocumentSymbolClientCapabilities
-> DocumentSymbolClientCapabilities -> Bool
DocumentSymbolClientCapabilities
-> DocumentSymbolClientCapabilities -> Ordering
DocumentSymbolClientCapabilities
-> DocumentSymbolClientCapabilities
-> DocumentSymbolClientCapabilities
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 :: DocumentSymbolClientCapabilities
-> DocumentSymbolClientCapabilities
-> DocumentSymbolClientCapabilities
$cmin :: DocumentSymbolClientCapabilities
-> DocumentSymbolClientCapabilities
-> DocumentSymbolClientCapabilities
max :: DocumentSymbolClientCapabilities
-> DocumentSymbolClientCapabilities
-> DocumentSymbolClientCapabilities
$cmax :: DocumentSymbolClientCapabilities
-> DocumentSymbolClientCapabilities
-> DocumentSymbolClientCapabilities
>= :: DocumentSymbolClientCapabilities
-> DocumentSymbolClientCapabilities -> Bool
$c>= :: DocumentSymbolClientCapabilities
-> DocumentSymbolClientCapabilities -> Bool
> :: DocumentSymbolClientCapabilities
-> DocumentSymbolClientCapabilities -> Bool
$c> :: DocumentSymbolClientCapabilities
-> DocumentSymbolClientCapabilities -> Bool
<= :: DocumentSymbolClientCapabilities
-> DocumentSymbolClientCapabilities -> Bool
$c<= :: DocumentSymbolClientCapabilities
-> DocumentSymbolClientCapabilities -> Bool
< :: DocumentSymbolClientCapabilities
-> DocumentSymbolClientCapabilities -> Bool
$c< :: DocumentSymbolClientCapabilities
-> DocumentSymbolClientCapabilities -> Bool
compare :: DocumentSymbolClientCapabilities
-> DocumentSymbolClientCapabilities -> Ordering
$ccompare :: DocumentSymbolClientCapabilities
-> DocumentSymbolClientCapabilities -> Ordering
Ord, forall x.
Rep DocumentSymbolClientCapabilities x
-> DocumentSymbolClientCapabilities
forall x.
DocumentSymbolClientCapabilities
-> Rep DocumentSymbolClientCapabilities x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep DocumentSymbolClientCapabilities x
-> DocumentSymbolClientCapabilities
$cfrom :: forall x.
DocumentSymbolClientCapabilities
-> Rep DocumentSymbolClientCapabilities x
Generic)
deriving anyclass (DocumentSymbolClientCapabilities -> ()
forall a. (a -> ()) -> NFData a
rnf :: DocumentSymbolClientCapabilities -> ()
$crnf :: DocumentSymbolClientCapabilities -> ()
NFData, Eq DocumentSymbolClientCapabilities
Int -> DocumentSymbolClientCapabilities -> Int
DocumentSymbolClientCapabilities -> Int
forall a. Eq a -> (Int -> a -> Int) -> (a -> Int) -> Hashable a
hash :: DocumentSymbolClientCapabilities -> Int
$chash :: DocumentSymbolClientCapabilities -> Int
hashWithSalt :: Int -> DocumentSymbolClientCapabilities -> Int
$chashWithSalt :: Int -> DocumentSymbolClientCapabilities -> Int
Hashable)
deriving forall ann. [DocumentSymbolClientCapabilities] -> Doc ann
forall ann. DocumentSymbolClientCapabilities -> Doc ann
forall a.
(forall ann. a -> Doc ann)
-> (forall ann. [a] -> Doc ann) -> Pretty a
prettyList :: forall ann. [DocumentSymbolClientCapabilities] -> Doc ann
$cprettyList :: forall ann. [DocumentSymbolClientCapabilities] -> Doc ann
pretty :: forall ann. DocumentSymbolClientCapabilities -> Doc ann
$cpretty :: forall ann. DocumentSymbolClientCapabilities -> Doc ann
Pretty via (ViaJSON DocumentSymbolClientCapabilities)
instance Aeson.ToJSON DocumentSymbolClientCapabilities where
toJSON :: DocumentSymbolClientCapabilities -> Value
toJSON (DocumentSymbolClientCapabilities Maybe Bool
arg0 Maybe
(Rec (Extend "valueSet" (Maybe [SymbolKind]) ('R '[]) .+ 'R '[]))
arg1 Maybe Bool
arg2 Maybe (Rec (Extend "valueSet" [SymbolTag] ('R '[]) .+ 'R '[]))
arg3 Maybe Bool
arg4) = [Pair] -> Value
Aeson.object forall a b. (a -> b) -> a -> b
$ forall (t :: * -> *) a. Foldable t => t [a] -> [a]
concat forall a b. (a -> b) -> a -> b
$ [String
"dynamicRegistration" forall kv v. (KeyValue kv, ToJSON v) => String -> Maybe v -> [kv]
Language.LSP.Protocol.Types.Common..=? Maybe Bool
arg0
,String
"symbolKind" forall kv v. (KeyValue kv, ToJSON v) => String -> Maybe v -> [kv]
Language.LSP.Protocol.Types.Common..=? Maybe
(Rec (Extend "valueSet" (Maybe [SymbolKind]) ('R '[]) .+ 'R '[]))
arg1
,String
"hierarchicalDocumentSymbolSupport" forall kv v. (KeyValue kv, ToJSON v) => String -> Maybe v -> [kv]
Language.LSP.Protocol.Types.Common..=? Maybe Bool
arg2
,String
"tagSupport" forall kv v. (KeyValue kv, ToJSON v) => String -> Maybe v -> [kv]
Language.LSP.Protocol.Types.Common..=? Maybe (Rec (Extend "valueSet" [SymbolTag] ('R '[]) .+ 'R '[]))
arg3
,String
"labelSupport" forall kv v. (KeyValue kv, ToJSON v) => String -> Maybe v -> [kv]
Language.LSP.Protocol.Types.Common..=? Maybe Bool
arg4]
instance Aeson.FromJSON DocumentSymbolClientCapabilities where
parseJSON :: Value -> Parser DocumentSymbolClientCapabilities
parseJSON = forall a. String -> (Object -> Parser a) -> Value -> Parser a
Aeson.withObject String
"DocumentSymbolClientCapabilities" forall a b. (a -> b) -> a -> b
$ \Object
arg -> Maybe Bool
-> Maybe
(Rec (Extend "valueSet" (Maybe [SymbolKind]) ('R '[]) .+ 'R '[]))
-> Maybe Bool
-> Maybe (Rec (Extend "valueSet" [SymbolTag] ('R '[]) .+ 'R '[]))
-> Maybe Bool
-> DocumentSymbolClientCapabilities
DocumentSymbolClientCapabilities forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
<$> Object
arg forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Aeson..:! Key
"dynamicRegistration" forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
<*> Object
arg forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Aeson..:! Key
"symbolKind" forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
<*> Object
arg forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Aeson..:! Key
"hierarchicalDocumentSymbolSupport" forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
<*> Object
arg forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Aeson..:! Key
"tagSupport" forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
<*> Object
arg forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Aeson..:! Key
"labelSupport"