{-# LANGUAGE TemplateHaskell #-}
{-# LANGUAGE TypeOperators #-}
{-# LANGUAGE DuplicateRecordFields #-}
module Language.LSP.Types.ServerCapabilities where
import Data.Aeson
import Data.Aeson.TH
import Data.Text (Text)
import Language.LSP.Types.CallHierarchy
import Language.LSP.Types.CodeAction
import Language.LSP.Types.CodeLens
import Language.LSP.Types.Command
import Language.LSP.Types.Common
import Language.LSP.Types.Completion
import Language.LSP.Types.Declaration
import Language.LSP.Types.Definition
import Language.LSP.Types.DocumentColor
import Language.LSP.Types.DocumentHighlight
import Language.LSP.Types.DocumentLink
import Language.LSP.Types.DocumentSymbol
import Language.LSP.Types.FoldingRange
import Language.LSP.Types.Formatting
import Language.LSP.Types.Hover
import Language.LSP.Types.Implementation
import Language.LSP.Types.References
import Language.LSP.Types.Rename
import Language.LSP.Types.SelectionRange
import Language.LSP.Types.SemanticTokens
import Language.LSP.Types.SignatureHelp
import Language.LSP.Types.TextDocument
import Language.LSP.Types.TypeDefinition
import Language.LSP.Types.Utils
import Language.LSP.Types.WorkspaceSymbol
data =
{
WorkspaceFoldersServerCapabilities -> Maybe Bool
_supported :: Maybe Bool
, WorkspaceFoldersServerCapabilities -> Maybe (Text |? Bool)
_changeNotifications :: Maybe (Text |? Bool)
}
deriving (Int -> WorkspaceFoldersServerCapabilities -> ShowS
[WorkspaceFoldersServerCapabilities] -> ShowS
WorkspaceFoldersServerCapabilities -> String
(Int -> WorkspaceFoldersServerCapabilities -> ShowS)
-> (WorkspaceFoldersServerCapabilities -> String)
-> ([WorkspaceFoldersServerCapabilities] -> ShowS)
-> Show WorkspaceFoldersServerCapabilities
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> WorkspaceFoldersServerCapabilities -> ShowS
showsPrec :: Int -> WorkspaceFoldersServerCapabilities -> ShowS
$cshow :: WorkspaceFoldersServerCapabilities -> String
show :: WorkspaceFoldersServerCapabilities -> String
$cshowList :: [WorkspaceFoldersServerCapabilities] -> ShowS
showList :: [WorkspaceFoldersServerCapabilities] -> ShowS
Show, ReadPrec [WorkspaceFoldersServerCapabilities]
ReadPrec WorkspaceFoldersServerCapabilities
Int -> ReadS WorkspaceFoldersServerCapabilities
ReadS [WorkspaceFoldersServerCapabilities]
(Int -> ReadS WorkspaceFoldersServerCapabilities)
-> ReadS [WorkspaceFoldersServerCapabilities]
-> ReadPrec WorkspaceFoldersServerCapabilities
-> ReadPrec [WorkspaceFoldersServerCapabilities]
-> Read WorkspaceFoldersServerCapabilities
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
$creadsPrec :: Int -> ReadS WorkspaceFoldersServerCapabilities
readsPrec :: Int -> ReadS WorkspaceFoldersServerCapabilities
$creadList :: ReadS [WorkspaceFoldersServerCapabilities]
readList :: ReadS [WorkspaceFoldersServerCapabilities]
$creadPrec :: ReadPrec WorkspaceFoldersServerCapabilities
readPrec :: ReadPrec WorkspaceFoldersServerCapabilities
$creadListPrec :: ReadPrec [WorkspaceFoldersServerCapabilities]
readListPrec :: ReadPrec [WorkspaceFoldersServerCapabilities]
Read, WorkspaceFoldersServerCapabilities
-> WorkspaceFoldersServerCapabilities -> Bool
(WorkspaceFoldersServerCapabilities
-> WorkspaceFoldersServerCapabilities -> Bool)
-> (WorkspaceFoldersServerCapabilities
-> WorkspaceFoldersServerCapabilities -> Bool)
-> Eq WorkspaceFoldersServerCapabilities
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: WorkspaceFoldersServerCapabilities
-> WorkspaceFoldersServerCapabilities -> Bool
== :: WorkspaceFoldersServerCapabilities
-> WorkspaceFoldersServerCapabilities -> Bool
$c/= :: WorkspaceFoldersServerCapabilities
-> WorkspaceFoldersServerCapabilities -> Bool
/= :: WorkspaceFoldersServerCapabilities
-> WorkspaceFoldersServerCapabilities -> Bool
Eq)
deriveJSON lspOptions ''WorkspaceFoldersServerCapabilities
data WorkspaceServerCapabilities =
WorkspaceServerCapabilities
{
WorkspaceServerCapabilities
-> Maybe WorkspaceFoldersServerCapabilities
_workspaceFolders :: Maybe WorkspaceFoldersServerCapabilities
}
deriving (Int -> WorkspaceServerCapabilities -> ShowS
[WorkspaceServerCapabilities] -> ShowS
WorkspaceServerCapabilities -> String
(Int -> WorkspaceServerCapabilities -> ShowS)
-> (WorkspaceServerCapabilities -> String)
-> ([WorkspaceServerCapabilities] -> ShowS)
-> Show WorkspaceServerCapabilities
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> WorkspaceServerCapabilities -> ShowS
showsPrec :: Int -> WorkspaceServerCapabilities -> ShowS
$cshow :: WorkspaceServerCapabilities -> String
show :: WorkspaceServerCapabilities -> String
$cshowList :: [WorkspaceServerCapabilities] -> ShowS
showList :: [WorkspaceServerCapabilities] -> ShowS
Show, ReadPrec [WorkspaceServerCapabilities]
ReadPrec WorkspaceServerCapabilities
Int -> ReadS WorkspaceServerCapabilities
ReadS [WorkspaceServerCapabilities]
(Int -> ReadS WorkspaceServerCapabilities)
-> ReadS [WorkspaceServerCapabilities]
-> ReadPrec WorkspaceServerCapabilities
-> ReadPrec [WorkspaceServerCapabilities]
-> Read WorkspaceServerCapabilities
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
$creadsPrec :: Int -> ReadS WorkspaceServerCapabilities
readsPrec :: Int -> ReadS WorkspaceServerCapabilities
$creadList :: ReadS [WorkspaceServerCapabilities]
readList :: ReadS [WorkspaceServerCapabilities]
$creadPrec :: ReadPrec WorkspaceServerCapabilities
readPrec :: ReadPrec WorkspaceServerCapabilities
$creadListPrec :: ReadPrec [WorkspaceServerCapabilities]
readListPrec :: ReadPrec [WorkspaceServerCapabilities]
Read, WorkspaceServerCapabilities -> WorkspaceServerCapabilities -> Bool
(WorkspaceServerCapabilities
-> WorkspaceServerCapabilities -> Bool)
-> (WorkspaceServerCapabilities
-> WorkspaceServerCapabilities -> Bool)
-> Eq WorkspaceServerCapabilities
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: WorkspaceServerCapabilities -> WorkspaceServerCapabilities -> Bool
== :: WorkspaceServerCapabilities -> WorkspaceServerCapabilities -> Bool
$c/= :: WorkspaceServerCapabilities -> WorkspaceServerCapabilities -> Bool
/= :: WorkspaceServerCapabilities -> WorkspaceServerCapabilities -> Bool
Eq)
deriveJSON lspOptions ''WorkspaceServerCapabilities
data ServerCapabilities =
ServerCapabilities
{
ServerCapabilities
-> Maybe (TextDocumentSyncOptions |? TextDocumentSyncKind)
_textDocumentSync :: Maybe (TextDocumentSyncOptions |? TextDocumentSyncKind)
, ServerCapabilities -> Maybe (Bool |? HoverOptions)
_hoverProvider :: Maybe (Bool |? HoverOptions)
, ServerCapabilities -> Maybe CompletionOptions
_completionProvider :: Maybe CompletionOptions
, ServerCapabilities -> Maybe SignatureHelpOptions
_signatureHelpProvider :: Maybe SignatureHelpOptions
, ServerCapabilities
-> Maybe
(Bool |? (DeclarationOptions |? DeclarationRegistrationOptions))
_declarationProvider :: Maybe (Bool |? DeclarationOptions |? DeclarationRegistrationOptions)
, ServerCapabilities -> Maybe (Bool |? DefinitionOptions)
_definitionProvider :: Maybe (Bool |? DefinitionOptions)
, ServerCapabilities
-> Maybe
(Bool
|? (TypeDefinitionOptions |? TypeDefinitionRegistrationOptions))
_typeDefinitionProvider :: Maybe (Bool |? TypeDefinitionOptions |? TypeDefinitionRegistrationOptions)
, ServerCapabilities
-> Maybe
(Bool
|? (ImplementationOptions |? ImplementationRegistrationOptions))
_implementationProvider :: Maybe (Bool |? ImplementationOptions |? ImplementationRegistrationOptions)
, ServerCapabilities -> Maybe (Bool |? ReferenceOptions)
_referencesProvider :: Maybe (Bool |? ReferenceOptions)
, ServerCapabilities -> Maybe (Bool |? DocumentHighlightOptions)
_documentHighlightProvider :: Maybe (Bool |? DocumentHighlightOptions)
, ServerCapabilities -> Maybe (Bool |? DocumentSymbolOptions)
_documentSymbolProvider :: Maybe (Bool |? DocumentSymbolOptions)
, ServerCapabilities -> Maybe (Bool |? CodeActionOptions)
_codeActionProvider :: Maybe (Bool |? CodeActionOptions)
, ServerCapabilities -> Maybe CodeLensOptions
_codeLensProvider :: Maybe CodeLensOptions
, ServerCapabilities -> Maybe DocumentLinkOptions
_documentLinkProvider :: Maybe DocumentLinkOptions
, ServerCapabilities
-> Maybe
(Bool
|? (DocumentColorOptions |? DocumentColorRegistrationOptions))
_colorProvider :: Maybe (Bool |? DocumentColorOptions |? DocumentColorRegistrationOptions)
, ServerCapabilities -> Maybe (Bool |? DocumentFormattingOptions)
_documentFormattingProvider :: Maybe (Bool |? DocumentFormattingOptions)
, ServerCapabilities
-> Maybe (Bool |? DocumentRangeFormattingOptions)
_documentRangeFormattingProvider :: Maybe (Bool |? DocumentRangeFormattingOptions)
, ServerCapabilities -> Maybe DocumentOnTypeFormattingOptions
_documentOnTypeFormattingProvider :: Maybe DocumentOnTypeFormattingOptions
, ServerCapabilities -> Maybe (Bool |? RenameOptions)
_renameProvider :: Maybe (Bool |? RenameOptions)
, ServerCapabilities
-> Maybe
(Bool |? (FoldingRangeOptions |? FoldingRangeRegistrationOptions))
_foldingRangeProvider :: Maybe (Bool |? FoldingRangeOptions |? FoldingRangeRegistrationOptions)
, ServerCapabilities -> Maybe ExecuteCommandOptions
_executeCommandProvider :: Maybe ExecuteCommandOptions
, ServerCapabilities
-> Maybe
(Bool
|? (SelectionRangeOptions |? SelectionRangeRegistrationOptions))
_selectionRangeProvider :: Maybe (Bool |? SelectionRangeOptions |? SelectionRangeRegistrationOptions)
, ServerCapabilities
-> Maybe
(Bool
|? (CallHierarchyOptions |? CallHierarchyRegistrationOptions))
_callHierarchyProvider :: Maybe (Bool |? CallHierarchyOptions |? CallHierarchyRegistrationOptions)
, ServerCapabilities
-> Maybe
(SemanticTokensOptions |? SemanticTokensRegistrationOptions)
_semanticTokensProvider :: Maybe (SemanticTokensOptions |? SemanticTokensRegistrationOptions)
, ServerCapabilities -> Maybe (Bool |? WorkspaceSymbolOptions)
_workspaceSymbolProvider :: Maybe (Bool |? WorkspaceSymbolOptions)
, ServerCapabilities -> Maybe WorkspaceServerCapabilities
_workspace :: Maybe WorkspaceServerCapabilities
, ServerCapabilities -> Maybe Value
_experimental :: Maybe Value
} deriving (Int -> ServerCapabilities -> ShowS
[ServerCapabilities] -> ShowS
ServerCapabilities -> String
(Int -> ServerCapabilities -> ShowS)
-> (ServerCapabilities -> String)
-> ([ServerCapabilities] -> ShowS)
-> Show ServerCapabilities
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> ServerCapabilities -> ShowS
showsPrec :: Int -> ServerCapabilities -> ShowS
$cshow :: ServerCapabilities -> String
show :: ServerCapabilities -> String
$cshowList :: [ServerCapabilities] -> ShowS
showList :: [ServerCapabilities] -> ShowS
Show, ReadPrec [ServerCapabilities]
ReadPrec ServerCapabilities
Int -> ReadS ServerCapabilities
ReadS [ServerCapabilities]
(Int -> ReadS ServerCapabilities)
-> ReadS [ServerCapabilities]
-> ReadPrec ServerCapabilities
-> ReadPrec [ServerCapabilities]
-> Read ServerCapabilities
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
$creadsPrec :: Int -> ReadS ServerCapabilities
readsPrec :: Int -> ReadS ServerCapabilities
$creadList :: ReadS [ServerCapabilities]
readList :: ReadS [ServerCapabilities]
$creadPrec :: ReadPrec ServerCapabilities
readPrec :: ReadPrec ServerCapabilities
$creadListPrec :: ReadPrec [ServerCapabilities]
readListPrec :: ReadPrec [ServerCapabilities]
Read, ServerCapabilities -> ServerCapabilities -> Bool
(ServerCapabilities -> ServerCapabilities -> Bool)
-> (ServerCapabilities -> ServerCapabilities -> Bool)
-> Eq ServerCapabilities
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: ServerCapabilities -> ServerCapabilities -> Bool
== :: ServerCapabilities -> ServerCapabilities -> Bool
$c/= :: ServerCapabilities -> ServerCapabilities -> Bool
/= :: ServerCapabilities -> ServerCapabilities -> Bool
Eq)
deriveJSON lspOptions ''ServerCapabilities