public interface CodeDocumentationProvider extends DocumentationProvider
LanguageDocumentation
EP_NAME
Modifier and Type | Method and Description |
---|---|
PsiComment |
findExistingDocComment(PsiComment contextElement)
Finds primary documentation comment within given context.
|
java.lang.String |
generateDocumentationContentStub(PsiComment contextComment)
Generate documentation comment content for given context.
|
Pair<PsiElement,PsiComment> |
parseContext(PsiElement startPoint)
Examines PSI hierarchy identified by the given 'start' element trying to find element which can be documented
and it's doc comment (if any).
|
collectDocComments, generateDoc, generateHoverDoc, generateRenderedDoc, getCustomDocumentationElement, getDocumentationElementForLink, getDocumentationElementForLookupItem, getQuickNavigateInfo, getUrlFor
PsiComment findExistingDocComment(PsiComment contextElement)
contextElement
- candidate psi commentPair<PsiElement,PsiComment> parseContext(PsiElement startPoint)
int test() { return [caret] 1; }PSI element at the caret (return element) is an entry point. This method is expected to return PSI method element and
'null'
as the existing doc comment then.startPoint
- start traversal point'null'
as an indication that no doc comment anchor and existing comment
is available;
returned pair must have non-null PSI element and nullable existing comment references thenjava.lang.String generateDocumentationContentStub(PsiComment contextComment)
contextComment
- context psi comment