class Mint::LS::Definition
- Mint::LS::Definition
- LSP::RequestMessage
- Reference
- Object
Overview
This is the class that handles the "textDocument/definition" request.
Defined in:
ls/definition.crls/definition/connect.cr
ls/definition/connect_variable.cr
ls/definition/enum_destructuring.cr
ls/definition/enum_id.cr
ls/definition/html_attribute.cr
ls/definition/html_component.cr
ls/definition/html_element.cr
ls/definition/html_style.cr
ls/definition/type.cr
Constructors
-
.new(pull : JSON::PullParser)
This is the class that handles the "textDocument/definition" request.
Instance Method Summary
- #cursor_intersects?(node : Ast::Node, position : LSP::Position) : Bool
- #cursor_intersects?(node : Ast::Node, params : LSP::TextDocumentPositionParams) : Bool
- #cursor_intersects?(node : Ast::Node) : Bool
- #definition(node : Ast::Connect, server : Server, workspace : Workspace, stack : Array(Ast::Node))
- #definition(node : Ast::ConnectVariable, server : Server, workspace : Workspace, stack : Array(Ast::Node))
- #definition(node : Ast::EnumDestructuring, server : Server, workspace : Workspace, stack : Array(Ast::Node))
- #definition(node : Ast::EnumId, server : Server, workspace : Workspace, stack : Array(Ast::Node))
- #definition(node : Ast::HtmlAttribute, server : Server, workspace : Workspace, stack : Array(Ast::Node))
- #definition(node : Ast::HtmlComponent, server : Server, workspace : Workspace, stack : Array(Ast::Node))
- #definition(node : Ast::HtmlElement, server : Server, workspace : Workspace, stack : Array(Ast::Node))
- #definition(node : Ast::HtmlStyle, server : Server, workspace : Workspace, stack : Array(Ast::Node))
- #definition(node : Ast::Type, server : Server, workspace : Workspace, stack : Array(Ast::Node))
- #definition(node : Ast::Node, server : Server, workspace : Workspace, stack : Array(Ast::Node))
- #execute(server) : LSP::LocationLink | LSP::Location | Nil
- #find_component(workspace : Workspace, name : String) : Ast::Component | Nil
- #has_link_support?(server : Server)
-
#location_link(server : Server, source : Ast::Node, target : Ast::Node, parent : Ast::Node) : LSP::LocationLink | LSP::Location
Returns a
LSP::LocationLinkthat links from source to the target node if the language server client has link support, otherwise it returnsLSP::Location. - #params : LSP::TextDocumentPositionParams
- #params=(params : LSP::TextDocumentPositionParams)
- #to_lsp_range(location : Ast::Node::Location) : LSP::Range
Instance methods inherited from class LSP::RequestMessage
execute(server : Server)
execute,
id : Int32 | String
id,
id=(id : Int32 | String)
id=,
method : String
method,
method=(method : String)
method=
Constructor methods inherited from class LSP::RequestMessage
new(pull : JSON::PullParser)
new
Constructor Detail
This is the class that handles the "textDocument/definition" request.
Instance Method Detail
Returns a LSP::LocationLink that links from source to the target node
if the language server client has link support, otherwise it returns LSP::Location.
When returning a LSP::LocationLink, parent is used to provide the full range
for the target node. For example, for a function, target would be the function name,
and parent would be the whole node, including function body and any comments