public abstract class IntroduceFieldCentralPanel
extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
protected static Logger |
LOG |
protected boolean |
myAllowInitInMethod |
protected boolean |
myAllowInitInMethodIfAll |
protected PsiExpression |
myInitializerExpression |
protected boolean |
myIsCurrentMethodConstructor |
protected boolean |
myIsInvokedOnDeclaration |
protected PsiLocalVariable |
myLocalVariable |
protected int |
myOccurrencesCount |
protected PsiClass |
myParentClass |
protected TypeSelectorManager |
myTypeSelectorManager |
protected boolean |
myWillBeDeclaredStatic |
static boolean |
ourLastCbFinalState |
Constructor and Description |
---|
IntroduceFieldCentralPanel(PsiClass parentClass,
PsiExpression initializerExpression,
PsiLocalVariable localVariable,
boolean isCurrentMethodConstructor,
boolean isInvokedOnDeclaration,
boolean willBeDeclaredStatic,
PsiExpression[] occurrences,
boolean allowInitInMethod,
boolean allowInitInMethodIfAll,
TypeSelectorManager typeSelectorManager) |
Modifier and Type | Method and Description |
---|---|
void |
addOccurrenceListener(java.awt.event.ItemListener itemListener) |
protected boolean |
allowFinal() |
protected javax.swing.JPanel |
appendCheckboxes(java.awt.event.ItemListener itemListener) |
void |
appendOccurrences(java.awt.event.ItemListener itemListener,
java.awt.GridBagConstraints gbConstraints,
javax.swing.JPanel panel) |
protected abstract javax.swing.JPanel |
composeWholePanel(javax.swing.JComponent initializerPlacePanel,
javax.swing.JPanel checkboxPanel) |
protected javax.swing.JComponent |
createCenterPanel() |
protected abstract javax.swing.JComponent |
createInitializerPlacePanel(java.awt.event.ItemListener itemListener,
java.awt.event.ItemListener finalUpdater) |
protected void |
enableFinal(boolean enable) |
abstract java.lang.String |
getFieldVisibility() |
abstract BaseExpressionToFieldHandler.InitializationPlace |
getInitializerPlace() |
protected abstract boolean |
hasSetUpChoice() |
protected void |
initializeControls(PsiExpression initializerExpression,
BaseExpressionToFieldHandler.InitializationPlace ourLastInitializerPlace) |
protected abstract void |
initializeInitializerPlace(PsiExpression initializerExpression,
BaseExpressionToFieldHandler.InitializationPlace ourLastInitializerPlace) |
boolean |
isDeclareFinal() |
boolean |
isDeleteVariable() |
boolean |
isReplaceAllOccurrences() |
void |
saveFinalState() |
void |
setCreateFinal(boolean createFinal) |
protected boolean |
setEnabledInitializationPlaces(PsiExpression initializer) |
abstract void |
setInitializeInFieldDeclaration() |
void |
setReplaceAllOccurrences(boolean replaceAllOccurrences) |
abstract void |
setVisibility(java.lang.String visibility) |
protected boolean |
shouldUpdateTypeSelector() |
protected void |
updateCbFinal() |
protected abstract boolean |
updateInitializationPlaceModel(boolean initializedInsetup,
boolean initializedInConstructor,
boolean locals) |
protected void |
updateInitializerSelection() |
protected static final Logger LOG
public static boolean ourLastCbFinalState
protected final PsiClass myParentClass
protected final PsiExpression myInitializerExpression
protected final PsiLocalVariable myLocalVariable
protected final boolean myIsCurrentMethodConstructor
protected final boolean myIsInvokedOnDeclaration
protected final boolean myWillBeDeclaredStatic
protected final int myOccurrencesCount
protected final boolean myAllowInitInMethod
protected final boolean myAllowInitInMethodIfAll
protected final TypeSelectorManager myTypeSelectorManager
public IntroduceFieldCentralPanel(PsiClass parentClass, PsiExpression initializerExpression, PsiLocalVariable localVariable, boolean isCurrentMethodConstructor, boolean isInvokedOnDeclaration, boolean willBeDeclaredStatic, PsiExpression[] occurrences, boolean allowInitInMethod, boolean allowInitInMethodIfAll, TypeSelectorManager typeSelectorManager)
protected boolean setEnabledInitializationPlaces(PsiExpression initializer)
public abstract BaseExpressionToFieldHandler.InitializationPlace getInitializerPlace()
protected abstract void initializeInitializerPlace(PsiExpression initializerExpression, BaseExpressionToFieldHandler.InitializationPlace ourLastInitializerPlace)
protected abstract javax.swing.JComponent createInitializerPlacePanel(java.awt.event.ItemListener itemListener, java.awt.event.ItemListener finalUpdater)
public abstract void setInitializeInFieldDeclaration()
public abstract void setVisibility(java.lang.String visibility)
public abstract java.lang.String getFieldVisibility()
protected void initializeControls(PsiExpression initializerExpression, BaseExpressionToFieldHandler.InitializationPlace ourLastInitializerPlace)
public boolean isReplaceAllOccurrences()
public boolean isDeleteVariable()
public boolean isDeclareFinal()
protected javax.swing.JComponent createCenterPanel()
protected abstract javax.swing.JPanel composeWholePanel(javax.swing.JComponent initializerPlacePanel, javax.swing.JPanel checkboxPanel)
protected void updateInitializerSelection()
protected boolean shouldUpdateTypeSelector()
protected javax.swing.JPanel appendCheckboxes(java.awt.event.ItemListener itemListener)
public void appendOccurrences(java.awt.event.ItemListener itemListener, java.awt.GridBagConstraints gbConstraints, javax.swing.JPanel panel)
protected void updateCbFinal()
protected boolean allowFinal()
public void addOccurrenceListener(java.awt.event.ItemListener itemListener)
public void setReplaceAllOccurrences(boolean replaceAllOccurrences)
public void setCreateFinal(boolean createFinal)
protected void enableFinal(boolean enable)
public void saveFinalState()
protected abstract boolean updateInitializationPlaceModel(boolean initializedInsetup, boolean initializedInConstructor, boolean locals)
protected abstract boolean hasSetUpChoice()