Browse Source

update document

pull/7/head v0.1.0-v0.4.2
KUDO Shunsuke 3 years ago
parent
commit
2c748ec92e
  1. 3
      README.md
  2. 78
      doc/study.md

3
README.md

@ -1,6 +1,9 @@
# ddc-vim-lsp
vim-lsp for ddc.vim.
- ddc.vim : v0.4.2
<img src="https://user-images.githubusercontent.com/212602/131358924-a62bd611-81ea-413b-aba5-2439fc42ae66.png" width="600"><br>
## Required

78
doc/study.md

@ -1,3 +1,75 @@
# v0.1.0
```plantuml
box "vim/neovim" #A5D6A7
participant core
end box
box "ddc-vim-lsp" #FFCCBC
participant autoload
participant plugin
participant source
end box
box "ddc" #B2EBF2
participant ddc
end box
box "denops" #B2EBF2
participant denops
end box
box "vim-lsp" #B2EBF2
participant vimlsp as "vim-lsp"
end box
box "lsp" #BBDEFB
participant lsp as "lsp server"
end box
== input text ==
core -> ddc: detect input text
ddc -> source: gatherCandidates
source -> autoload: call ddc_vim_lsp#request
autoload ->> vimlsp: call lsp#send_request
source --> ddc: return empty candidates
...
group lsp sequence
vimlsp ->> lsp:
lsp ->> vimlsp:
end
vimlsp ->> autoload: callback
autoload -> vimlsp: call lsp#omni#get_vim_completion_items
return
autoload -> core: store lsp items
note right
store it on
vim global variable
endnote
autoload -> ddc: call ddc#refresh_candidates
return
...
ddc -> source: gatherCandidates
note right
"gatnerCandidates" is called automatically
to trigger by "ddc#refresh_candidates".
endnote
source -> denops: get lsp items
denops -> core: get variable
return variable
denops --> source: lsp items
source --> ddc: return candidates
```
# v0.0.1
```plantuml
@ -31,14 +103,16 @@ end box
core -> ddc: detect input text
ddc -> source: gatherCandidates
source -> autoload: call ddc_vim_lsp#request
autoload ->> vimlsp: call send_request
autoload ->> vimlsp: call lsp#send_request
group lsp sequence
vimlsp ->> lsp:
lsp ->> vimlsp:
end
vimlsp ->> autoload: call back
vimlsp ->> autoload: callback
autoload -> vimlsp: call lsp#omni#get_vim_completion_items
return
autoload ->> source: call anonymous func
source -> source: call toCandidates
source ->> ddc: return candidates

Loading…
Cancel
Save