public abstract class CreateClassMappingAction<T extends DomElement> extends CreateDomElementAction<T>
AnAction.TransparentUpdate
ACTIONS_KEY, EMPTY_ARRAY
Constructor and Description |
---|
CreateClassMappingAction(java.lang.Class<T> contextClass,
java.lang.String baseClass,
java.lang.String template) |
Modifier and Type | Method and Description |
---|---|
protected abstract DomElement |
createElement(T context) |
protected DomElement |
createElement(T context,
Editor editor,
PsiFile file,
Project project) |
protected DomElement |
createElement(T context,
Editor editor,
PsiFile file,
Project project,
PsiClass selectedClass) |
protected PsiClass |
getBaseClass(T context,
Project project,
java.lang.String baseClass) |
protected java.lang.String |
getChooserTitle() |
boolean |
startInWriteAction()
Indicate whether this action should be invoked inside write action.
|
getContextElement, invoke, isValidForFile, replaceElementValue
getHandler
actionPerformed, actionPerformedImpl, beforeActionPerformedUpdate, getCommandName, getEditor, update, update, update
addTextOverride, applyTextOverride, copyFrom, copyShortcutFrom, displayTextInToolbar, getEventProject, getShortcutSet, getTemplatePresentation, getTemplateText, isDefaultIcon, isEnabledInModalContext, isInInjectedContext, isTransparentUpdate, registerCustomShortcutSet, registerCustomShortcutSet, registerCustomShortcutSet, registerCustomShortcutSet, setDefaultIcon, setEnabledInModalContext, setInjectedContext, setShortcutSet, startInTransaction, toString, unregisterCustomShortcutSet, useSmallerFontForTextInToolbar
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
getElementToMakeWritable
isDumbAware
public CreateClassMappingAction(java.lang.Class<T> contextClass, java.lang.String baseClass, java.lang.String template)
protected DomElement createElement(T context, Editor editor, PsiFile file, Project project)
createElement
in class CreateDomElementAction<T extends DomElement>
protected DomElement createElement(T context, Editor editor, PsiFile file, Project project, PsiClass selectedClass)
protected java.lang.String getChooserTitle()
protected abstract DomElement createElement(T context)
protected PsiClass getBaseClass(T context, Project project, java.lang.String baseClass)
public boolean startInWriteAction()
WriteActionAware
false
if e.g. modal dialog is shown inside the action.
If false
is returned the action itself is responsible for starting write action
when needed, by calling Application.runWriteAction(Runnable)
.true
if the action requires a write action (default), false
otherwise.