|
Remote Systems v6.4.1 |
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.ibm.etools.systems.core.ui.compile.SystemCompileCommandEditPane
This class prompts the user to create or edit the contents of a single compile command. This edit pane is used in the Work With Compile Commands dialog.
So what is the "contract" the edit pane has to fulfill?
Field Summary | |
---|---|
protected boolean |
caseSensitive
|
protected ISystemValidator |
cmdLabelValidator
|
protected SystemCommandTextField |
commandField
|
protected SystemCompileManager |
compileManager
|
protected Control |
controlInError
|
static String |
copyright
|
protected SystemMessage |
errorMessage
|
protected boolean |
fromVerify
|
protected ISystemCompileCommandEditPaneHoster |
hoster
|
protected boolean |
ignoreChanges
|
protected SystemCompileCommand |
inputCompileCommand
|
protected Label |
labelLabel
|
protected Vector |
listeners
|
protected boolean |
newMode
|
protected SystemCompileType |
parentCompileType
|
protected Shell |
shell
|
protected boolean |
skipEventFiring
|
protected Text |
textLabel
|
protected SystemCmdSubstVarList |
varList
|
Constructor Summary | |
---|---|
SystemCompileCommandEditPane(SystemCompileManager compileManager,
Shell shell,
ISystemCompileCommandEditPaneHoster owner,
boolean caseSensitive)
Constructor |
Method Summary | |
---|---|
void |
addChangeListener(ISystemCompileCommandEditPaneListener l)
Identify a listener interested in any changes made to the filter string, as they happen |
protected void |
addFillerLine(Composite parent,
int nbrColumns)
Add a spacer line |
protected void |
addGrowableFillerLine(Composite parent,
int nbrColumns)
Add a spacer line that grows in height to absorb extra space |
protected void |
addSeparatorLine(Composite parent,
int nbrColumns)
Add a separator line. |
boolean |
areErrorsPending()
Are errors pending? |
protected boolean |
areFieldsComplete()
Must be overridden if createContents is overridden. |
void |
clearErrorMessage()
Clear any pending errors. |
void |
commandModified(String cmdText,
SystemMessage errorMessage)
Callback from SystemCommandTextField when the user modifies the command. |
void |
configureHeadingLabel(Label label)
In the Work With dialog, this edit pane is shown on the right side, beside the compile command selection list. |
boolean |
createCommandLabelLineControls(Composite parent,
int availableColumns)
Overridable entry point for subclasses that wish to put something to the right of the "Command:" label From interface ISystemCommandTextAdditionalGUIProvider. |
Control |
createContents(Composite parent)
Populate the pane with the GUI widgets |
boolean |
createExtraButtons(Composite parent,
int availableColumns)
Create additional buttons, to go under command prompt. |
protected void |
doInitializeFields()
Initialize the input fields based on the inputCompileCommand, and perhaps subsystem. |
protected void |
enableExtraButtons()
Enable/disable extra buttons added by subclass. |
protected void |
fireChangeEvent(SystemMessage error)
Fire an event to all registered listeners, that the user has changed the compile command. |
protected String |
getCommandText()
Get the command text as is, no massaging done. |
protected SystemCommandViewerConfiguration |
getCommandTextViewerConfiguration()
For child classes to return their own subclasses of the default configurator used to enable proposal support in the command entry field. |
protected String |
getCompileCommandLabelRBKey()
Overridable method that returns the key used to get the label (+".label") and tip (+".tooltip") for the default prompt for the compile command label. |
protected String |
getCompileCommandPromptRBKey()
Overridable method that returns the key used to get the label (+".label") and tip (+".tooltip") for the prompt for the compile command string. |
protected SystemCompileManager |
getCompileManager()
For subclasses: return the input compile manager |
Control |
getInitialFocusControl()
Return the control to recieve initial focus. |
protected SystemCompileCommand |
getInputCompileCommand()
Return the input compile command as given us in setCompileCommand |
protected ResourceBundle |
getResourceBundle()
Overridable method that returns the resource bundle to use for the mri we show by default. |
protected Shell |
getShell()
Return the shell given us in the ctor |
protected SystemConnection |
getSystemConnection()
For subclasses within the subsystem factory framework: return the system connection within which this dialog was launched. |
boolean |
isComplete()
Do not override. |
protected String |
preSaveMassage(String commandString)
Opportunity for subclasses to perform any additional massaging of the user-entered command string, just prior to saving it. |
protected void |
processCommandTextChange(String newText,
boolean hasError)
Method called as user types into the command field Encapsulated out so that it can be called from various types of listeners. |
protected void |
processExtraButtonsChanges(SystemCompileCommand currentCmd)
Overridable method for saving data in subclass-supplied additional GUI. |
void |
removeChangeListener(ISystemCompileCommandEditPaneListener l)
Remove a listener interested in any changes made to the filter string, as they happen |
protected void |
resetExtraButtons(SystemCompileCommand originalCmd)
Overridable method for resetting GUI in subclass-supplied additional GUI, when in "edit" mode |
protected void |
resetExtraButtonsForNewMode()
Overridable method for resetting GUI in subclass-supplied additional GUI, when in "new" mode |
protected void |
resetFields()
This is called in the work with compile commands dialog when the user selects "new", or selects another command. |
SystemCompileCommand |
saveChanges()
Save all pending changes. |
void |
setCommandMassager(ISystemMassager massager)
Set the action command massager. |
protected void |
setCommandText(String text)
Set the command text |
protected void |
setCommandTextViewerConfiguration(SystemCommandViewerConfiguration cmdAssistant)
For child classes (such as iSeries IFS) that need to dynamically change the command entry field configuration, on the fly. |
void |
setCommandValidator(ISystemValidator validator)
Set the action command validator. |
void |
setCompileCommand(SystemCompileType parentCompileType,
SystemCompileCommand compileCommand)
Set the input filter string, in edit mode. |
void |
setCompileLabelValidator(ISystemValidator validator)
Set the validator to use for the compile command. |
protected void |
setIgnoreChanges(boolean ignoreChanges)
Turn on ignore changes mode. |
void |
setSubstitutionVariableList(SystemCmdSubstVarList varList)
Set the substitution variable list that Insert Variable will use. |
SystemMessage |
validate(boolean skipLabel,
boolean skipString)
Does complete verification of input fields. |
protected SystemMessage |
validateLabelInput()
Validates compile command label as entered so far in the text field. |
protected SystemMessage |
validateStringInput()
Validates compile command string as entered so far in the text field. |
SystemMessage |
verify()
Does complete verification of input fields. |
void |
widgetDefaultSelected(SelectionEvent event)
User has selected something via enter/dbl-click |
void |
widgetSelected(SelectionEvent event)
User has selected something |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
public static final String copyright
protected Shell shell
protected ISystemCompileCommandEditPaneHoster hoster
protected SystemCompileManager compileManager
protected SystemCompileCommand inputCompileCommand
protected SystemCompileType parentCompileType
protected Vector listeners
protected SystemCmdSubstVarList varList
protected boolean newMode
protected boolean ignoreChanges
protected Label labelLabel
protected Text textLabel
protected SystemCommandTextField commandField
protected SystemMessage errorMessage
protected boolean skipEventFiring
protected boolean fromVerify
protected boolean caseSensitive
protected Control controlInError
protected ISystemValidator cmdLabelValidator
Constructor Detail |
public SystemCompileCommandEditPane(SystemCompileManager compileManager, Shell shell, ISystemCompileCommandEditPaneHoster owner, boolean caseSensitive)
compileManager
- - the compile manager owner of this compile commandshell
- - the shell of the wizard or dialog host thisowner
- - the dialog or property page hosting this edit paneMethod Detail |
protected Shell getShell()
protected SystemCompileCommand getInputCompileCommand()
protected SystemCompileManager getCompileManager()
protected SystemConnection getSystemConnection()
public void setCompileLabelValidator(ISystemValidator validator)
protected void setIgnoreChanges(boolean ignoreChanges)
public void addChangeListener(ISystemCompileCommandEditPaneListener l)
public void removeChangeListener(ISystemCompileCommandEditPaneListener l)
public void setCommandValidator(ISystemValidator validator)
public void setCommandMassager(ISystemMassager massager)
public void setSubstitutionVariableList(SystemCmdSubstVarList varList)
protected SystemCommandViewerConfiguration getCommandTextViewerConfiguration()
protected void setCommandTextViewerConfiguration(SystemCommandViewerConfiguration cmdAssistant)
public void setCompileCommand(SystemCompileType parentCompileType, SystemCompileCommand compileCommand)
public SystemCompileCommand saveChanges()
protected String preSaveMassage(String commandString)
public void configureHeadingLabel(Label label)
This method gives subclasses the opportunity to specify unique values for this label. In addition to setting the text, the tooltip text should also be set.
public Control createContents(Composite parent)
parent
-
public Control getInitialFocusControl()
public boolean createCommandLabelLineControls(Composite parent, int availableColumns)
createCommandLabelLineControls
in interface ISystemCommandTextAdditionalGUIProvider
public boolean createExtraButtons(Composite parent, int availableColumns)
createExtraButtons
in interface ISystemCommandTextAdditionalGUIProvider
protected void enableExtraButtons()
protected void resetExtraButtonsForNewMode()
protected void resetExtraButtons(SystemCompileCommand originalCmd)
protected void processExtraButtonsChanges(SystemCompileCommand currentCmd)
protected ResourceBundle getResourceBundle()
Not used if you override createContents
protected String getCompileCommandLabelRBKey()
Not used if you override createContents
protected String getCompileCommandPromptRBKey()
Not used if you override createContents
protected void doInitializeFields()
protected void resetFields()
public boolean isComplete()
This is called by the dialog when first shown, to decide if the default information is complete enough to enable finish. It doesn't do validation, that will be done when finish is pressed.
protected boolean areFieldsComplete()
This is called by the isComplete, to decide if the default information is complete enough to enable finish. It doesn't do validation, that will be done when finish is pressed.
public boolean areErrorsPending()
public void clearErrorMessage()
public void commandModified(String cmdText, SystemMessage errorMessage)
commandModified
in interface ISystemCommandTextModifyListener
cmdText
- - current contents of the fielderrorMessage
- - potential error detected by the default validatorprotected void processCommandTextChange(String newText, boolean hasError)
protected void setCommandText(String text)
protected String getCommandText()
protected void fireChangeEvent(SystemMessage error)
Because this is used to enable/disable the Next and Finish buttons it is important to call it when asked to do verification, even if nothing has changed.
It is more efficient, however, to defer the event firing during a full verification until after the last widget has been verified. To enable this, set the protected variable "skipEventFiring" to true at the top of your verify event, then to "false" at the end. Then do fireChangeEvent(errorMessage);
protected SystemMessage validateLabelInput()
protected SystemMessage validateStringInput()
public SystemMessage validate(boolean skipLabel, boolean skipString)
public SystemMessage verify()
public void widgetSelected(SelectionEvent event)
public void widgetDefaultSelected(SelectionEvent event)
protected void addSeparatorLine(Composite parent, int nbrColumns)
protected void addFillerLine(Composite parent, int nbrColumns)
protected void addGrowableFillerLine(Composite parent, int nbrColumns)
|
Remote Systems v6.4.1 |
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |