{-# LANGUAGE TemplateHaskell #-}
{-# LANGUAGE DuplicateRecordFields #-}
module Language.LSP.Types.DocumentLink where
import Data.Aeson
import Data.Aeson.TH
import Language.LSP.Types.Location
import Language.LSP.Types.Progress
import Language.LSP.Types.TextDocument
import Language.LSP.Types.Uri
import Language.LSP.Types.Utils
import Data.Text (Text)
data DocumentLinkClientCapabilities =
DocumentLinkClientCapabilities
{
DocumentLinkClientCapabilities -> Maybe Bool
_dynamicRegistration :: Maybe Bool
, DocumentLinkClientCapabilities -> Maybe Bool
_tooltipSupport :: Maybe Bool
} deriving (ReadPrec [DocumentLinkClientCapabilities]
ReadPrec DocumentLinkClientCapabilities
Int -> ReadS DocumentLinkClientCapabilities
ReadS [DocumentLinkClientCapabilities]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [DocumentLinkClientCapabilities]
$creadListPrec :: ReadPrec [DocumentLinkClientCapabilities]
readPrec :: ReadPrec DocumentLinkClientCapabilities
$creadPrec :: ReadPrec DocumentLinkClientCapabilities
readList :: ReadS [DocumentLinkClientCapabilities]
$creadList :: ReadS [DocumentLinkClientCapabilities]
readsPrec :: Int -> ReadS DocumentLinkClientCapabilities
$creadsPrec :: Int -> ReadS DocumentLinkClientCapabilities
Read, Int -> DocumentLinkClientCapabilities -> ShowS
[DocumentLinkClientCapabilities] -> ShowS
DocumentLinkClientCapabilities -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [DocumentLinkClientCapabilities] -> ShowS
$cshowList :: [DocumentLinkClientCapabilities] -> ShowS
show :: DocumentLinkClientCapabilities -> String
$cshow :: DocumentLinkClientCapabilities -> String
showsPrec :: Int -> DocumentLinkClientCapabilities -> ShowS
$cshowsPrec :: Int -> DocumentLinkClientCapabilities -> ShowS
Show, DocumentLinkClientCapabilities
-> DocumentLinkClientCapabilities -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: DocumentLinkClientCapabilities
-> DocumentLinkClientCapabilities -> Bool
$c/= :: DocumentLinkClientCapabilities
-> DocumentLinkClientCapabilities -> Bool
== :: DocumentLinkClientCapabilities
-> DocumentLinkClientCapabilities -> Bool
$c== :: DocumentLinkClientCapabilities
-> DocumentLinkClientCapabilities -> Bool
Eq)
deriveJSON lspOptions ''DocumentLinkClientCapabilities
makeExtendingDatatype "DocumentLinkOptions" [''WorkDoneProgressOptions]
[("_resolveProvider", [t| Maybe Bool |])]
deriveJSON lspOptions ''DocumentLinkOptions
makeExtendingDatatype "DocumentLinkRegistrationOptions"
[ ''TextDocumentRegistrationOptions
, ''DocumentLinkOptions
] []
deriveJSON lspOptions ''DocumentLinkRegistrationOptions
makeExtendingDatatype "DocumentLinkParams"
[ ''WorkDoneProgressParams
, ''PartialResultParams
]
[("_textDocument", [t| TextDocumentIdentifier |])]
deriveJSON lspOptions ''DocumentLinkParams
data DocumentLink =
DocumentLink
{
DocumentLink -> Range
_range :: Range
, DocumentLink -> Maybe Uri
_target :: Maybe Uri
, DocumentLink -> Maybe Text
_tooltip :: Maybe Text
, DocumentLink -> Maybe Value
_xdata :: Maybe Value
} deriving (ReadPrec [DocumentLink]
ReadPrec DocumentLink
Int -> ReadS DocumentLink
ReadS [DocumentLink]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [DocumentLink]
$creadListPrec :: ReadPrec [DocumentLink]
readPrec :: ReadPrec DocumentLink
$creadPrec :: ReadPrec DocumentLink
readList :: ReadS [DocumentLink]
$creadList :: ReadS [DocumentLink]
readsPrec :: Int -> ReadS DocumentLink
$creadsPrec :: Int -> ReadS DocumentLink
Read, Int -> DocumentLink -> ShowS
[DocumentLink] -> ShowS
DocumentLink -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [DocumentLink] -> ShowS
$cshowList :: [DocumentLink] -> ShowS
show :: DocumentLink -> String
$cshow :: DocumentLink -> String
showsPrec :: Int -> DocumentLink -> ShowS
$cshowsPrec :: Int -> DocumentLink -> ShowS
Show, DocumentLink -> DocumentLink -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: DocumentLink -> DocumentLink -> Bool
$c/= :: DocumentLink -> DocumentLink -> Bool
== :: DocumentLink -> DocumentLink -> Bool
$c== :: DocumentLink -> DocumentLink -> Bool
Eq)
deriveJSON lspOptions ''DocumentLink