public class ExtendedTagInsertHandler extends XmlTagInsertHandler
Modifier and Type | Field and Description |
---|---|
protected java.lang.String |
myElementName |
protected java.lang.String |
myNamespace |
protected java.lang.String |
myNamespacePrefix |
INSTANCE
Constructor and Description |
---|
ExtendedTagInsertHandler(java.lang.String elementName,
java.lang.String namespace,
java.lang.String namespacePrefix) |
Modifier and Type | Method and Description |
---|---|
protected void |
doDefault(InsertionContext context,
LookupElement item) |
protected java.util.Set<java.lang.String> |
getNamespaces(XmlFile file) |
static java.lang.String |
getPrefixByNamespace(XmlFile file,
java.lang.String namespace) |
void |
handleInsert(InsertionContext context,
LookupElement item)
Invoked inside atomic action.
|
protected boolean |
isNamespaceBound(PsiElement psiElement) |
static void |
qualifyWithPrefix(java.lang.String namespacePrefix,
PsiElement element) |
protected void |
qualifyWithPrefix(java.lang.String namespacePrefix,
PsiElement element,
Document document) |
static java.lang.String |
suggestPrefix(XmlFile file,
java.lang.String namespace) |
addTail, insertIncompleteTag
protected final java.lang.String myElementName
protected final java.lang.String myNamespace
protected final java.lang.String myNamespacePrefix
public ExtendedTagInsertHandler(java.lang.String elementName, java.lang.String namespace, java.lang.String namespacePrefix)
public void handleInsert(InsertionContext context, LookupElement item)
InsertHandler
handleInsert
in interface InsertHandler<LookupElement>
handleInsert
in class XmlTagInsertHandler
protected void doDefault(InsertionContext context, LookupElement item)
protected boolean isNamespaceBound(PsiElement psiElement)
public static java.lang.String getPrefixByNamespace(XmlFile file, java.lang.String namespace)
public static java.lang.String suggestPrefix(XmlFile file, java.lang.String namespace)
protected java.util.Set<java.lang.String> getNamespaces(XmlFile file)
protected void qualifyWithPrefix(java.lang.String namespacePrefix, PsiElement element, Document document)
public static void qualifyWithPrefix(java.lang.String namespacePrefix, PsiElement element)