public class CustomTemplateCallback
extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
protected java.util.Set<TemplateContextType> |
myApplicableContextTypes |
Constructor and Description |
---|
CustomTemplateCallback(Editor editor,
PsiFile file) |
Modifier and Type | Method and Description |
---|---|
void |
deleteTemplateKey(java.lang.String key) |
TemplateImpl |
findApplicableTemplate(java.lang.String key) |
java.util.List<TemplateImpl> |
findApplicableTemplates(java.lang.String key) |
PsiElement |
getContext() |
static PsiElement |
getContext(PsiFile file,
int offset) |
static PsiElement |
getContext(PsiFile file,
int offset,
boolean searchInInjectedFragment) |
Editor |
getEditor() |
PsiFile |
getFile() |
FileType |
getFileType() |
int |
getOffset() |
static int |
getOffset(Editor editor) |
Project |
getProject() |
TemplateManager |
getTemplateManager() |
boolean |
isInInjectedFragment() |
void |
startTemplate(Template template,
java.util.Map<java.lang.String,java.lang.String> predefinedValues,
TemplateEditingListener listener) |
protected java.util.Set<TemplateContextType> myApplicableContextTypes
public TemplateManager getTemplateManager()
public PsiFile getFile()
public PsiElement getContext()
public int getOffset()
public static int getOffset(Editor editor)
public TemplateImpl findApplicableTemplate(java.lang.String key)
public java.util.List<TemplateImpl> findApplicableTemplates(java.lang.String key)
public void startTemplate(Template template, java.util.Map<java.lang.String,java.lang.String> predefinedValues, TemplateEditingListener listener)
public Editor getEditor()
public FileType getFileType()
public Project getProject()
public void deleteTemplateKey(java.lang.String key)
public static PsiElement getContext(PsiFile file, int offset)
public static PsiElement getContext(PsiFile file, int offset, boolean searchInInjectedFragment)
public boolean isInInjectedFragment()