haskell-lsp-0.14.0.0: Haskell library for the Microsoft Language Server Protocol

Safe HaskellNone
LanguageHaskell2010

Language.Haskell.LSP.VFS

Contents

Synopsis

Documentation

data VirtualFile Source #

Constructors

VirtualFile 
Instances
Show VirtualFile Source # 
Instance details

Defined in Language.Haskell.LSP.VFS

openVFS :: VFS -> DidOpenTextDocumentNotification -> IO VFS Source #

changeFromClientVFS :: VFS -> DidChangeTextDocumentNotification -> IO VFS Source #

changeFromServerVFS :: VFS -> ApplyWorkspaceEditRequest -> IO VFS Source #

closeVFS :: VFS -> DidCloseTextDocumentNotification -> IO VFS Source #

manipulating the file contents

data PosPrefixInfo Source #

Describes the line at the current cursor position

Constructors

PosPrefixInfo 

Fields

  • fullLine :: Text

    The full contents of the line the cursor is at

  • prefixModule :: Text

    If any, the module name that was typed right before the cursor position. For example, if the user has typed "Data.Maybe.from", then this property will be Data.Maybe

  • prefixText :: Text

    The word right before the cursor position, after removing the module part. For example if the user has typed "Data.Maybe.from", then this property will be "from"

  • cursorPos :: Position

    The cursor position

for tests

applyChanges :: Rope -> [TextDocumentContentChangeEvent] -> Rope Source #

Apply the list of changes. Changes should be applied in the order that they are received from the client.

applyChange :: Rope -> TextDocumentContentChangeEvent -> Rope Source #