Rational Developer for Power Systems Software
V7.6

com.ibm.etools.iseries.rse.ui.widgets
Class QSYSAspDevPrompt

java.lang.Object
  extended by Composite
      extended by com.ibm.etools.iseries.rse.ui.widgets.QSYSBasePrompt
          extended by com.ibm.etools.iseries.rse.ui.widgets.QSYSAspDevPrompt
All Implemented Interfaces:
IIBMiHistoryKeys

public class QSYSAspDevPrompt
extends QSYSBasePrompt
implements IIBMiHistoryKeys

This re-usable composite widget is for prompting the user for an ASP device description name, which is a *DEVD object of attribute ASP, only available in library QSYS

This is a commonly required parameter for many iSeries create commands. The aspdev name widget is a combo that lists special values and previously entered (historical) names. Beside the combo is a button with a Browse label for selecting an asp devd from a remote list.

The composite is layed as follows:


   ASP device description: ______________________v  Browse...
 

See Also:
#setASPDEVChangeListener(IAS400ASPDEVPromptListener)

Field Summary
 String[] ASPDEV_VALUES
           
protected  ValidatorIBMiObject aspDevValidator
           
protected  boolean autMode
           
static String copyright
           
protected  IQSYSAspDevPromptListener listener
           
 
Fields inherited from class com.ibm.etools.iseries.rse.ui.widgets.QSYSBasePrompt
browseAction, browseButton, defaultConnection, enableBrowse, gridColumns, ignoreChanges, onlyConnection, promptCombo, promptLabel, rb, showNewConnection, testing
 
Fields inherited from interface com.ibm.etools.iseries.rse.ui.IIBMiHistoryKeys
ATTR_OBJ, Copyright, GENERIC_ATTR_OBJ, GENERIC_NAME_CMD, GENERIC_NAME_DTAARA, GENERIC_NAME_DTAQ, GENERIC_NAME_FILE, GENERIC_NAME_FILE_DSPF, GENERIC_NAME_FILE_DSPF_PRTF, GENERIC_NAME_FILE_DTA, GENERIC_NAME_FILE_PRTF, GENERIC_NAME_FILE_SRC, GENERIC_NAME_FILE_SRC_DTA, GENERIC_NAME_FLD, GENERIC_NAME_JOBD, GENERIC_NAME_LIB, GENERIC_NAME_LIB_NOLIBL, GENERIC_NAME_MBR, GENERIC_NAME_MODULE, GENERIC_NAME_MSGF, GENERIC_NAME_OBJ, GENERIC_NAME_PGM, GENERIC_NAME_PGM_SRVPGM, GENERIC_NAME_RCD, GENERIC_NAME_SRVPGM, GENERIC_PREFIX, GENERIC_TYPE_MBR, GENERIC_TYPE_OBJ, HISTORY_PREFIX, JOB_CURR_USERID, JOB_NAME, JOB_NUMBER, JOB_SUBSYSTEM, JOB_USER, KEY_NAME, NAME_ASPDEV, NAME_AUTL, NAME_AUTL_AUT, NAME_AUTL_CRTAUT, NAME_CMD, NAME_DTAARA, NAME_DTAQ, NAME_FILE, NAME_FILE_DSPF, NAME_FILE_DSPF_PRTF, NAME_FILE_DTA, NAME_FILE_PRTF, NAME_FILE_SRC, NAME_FILE_SRC_DTA, NAME_FLD, NAME_JOBD, NAME_LIB, NAME_LIB_NOCURLIB, NAME_LIB_NOLIBL, NAME_MBR, NAME_MODULE, NAME_MSGF, NAME_OBJ, NAME_PGM, NAME_PGM_SRVPGM, NAME_RCD, NAME_SRVPGM, RELEASE_JOB_COMMAND, SAVF_LIB_HISTORY_KEY, SAVF_OBJ_HISTORY_KEY, SAVF_RSTLIB_HISTORY_KEY, SAVF_SAVELIB_HISTORY_KEY, SPLF_FILE, SPLF_USER, STRING_FIND, TYPE_MBR, TYPE_OBJ
 
Constructor Summary
QSYSAspDevPrompt(Composite parent, int style, IHost connection)
          Constructor
 
Method Summary
protected  void addOurButtonSelectionListener()
          AspDev's Browse button pressed handler
 String getAspDevName()
          Get the user entered or selected asp dev name.
protected  IIBMiSelectAction getBrowseAction(Shell shell, IHost defaultConnection, boolean onlyConnection)
          Overridable method.
protected  boolean isSpecialValue(String value)
          Test if given value is one of the special values...
protected  void populateCombo(SystemHistoryCombo combo)
          Populates the library combo.
 void setAspDevChangeListener(IQSYSAspDevPromptListener listener)
          Identify a caller that is interested in being informed of live error checking status
 void setAspDevName(String name)
          Set the asp device name or special value displayed in the combo box.
 void setDefaultConnection(IHost defaultConnection)
          Set the default connection to preselect when Browse is pressed.
 void setPromptLabel(String label)
          Set the prompt label.
 void setSystemConnection(IHost onlyConnection)
          Set the system connection to use when Browse is pressed.
 SystemMessage validateAspDevInput()
          Validate asp device name, as it is typed, or in batch if you wish to call directly.
 
Methods inherited from class com.ibm.etools.iseries.rse.ui.widgets.QSYSBasePrompt
addBrowseButtonSelectionListener, addModifyListener, addSelectionChangedListener, addSelectionListener, createCombo, createHistoryCombo, createPushButton, createPushButton, getBrowseButton, getCombo, getGridColumns, getItems, getPromptLabel, getSelection, getText, lineUpWith, lineUpWith, prepareComposite, removeBrowseButtonSelectionListener, removeModifyListener, removeSelectionChangedListener, removeSelectionListener, setBrowseButtonFocus, setBrowseButtonLabel, setBrowseButtonToolTipText, setButtonWidthHint, setButtonWidthHint, setEnabled, setFocus, setHost, setIgnoreChanges, setItems, setSelection, setShowNewConnectionPrompt, setText, setToolTipText, setWidthHint, showBrowseButton, showBrowseButton, updateHistory, updateHistory
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

copyright

public static final String copyright
See Also:
Constant Field Values

autMode

protected boolean autMode

listener

protected IQSYSAspDevPromptListener listener

aspDevValidator

protected ValidatorIBMiObject aspDevValidator

ASPDEV_VALUES

public String[] ASPDEV_VALUES
Constructor Detail

QSYSAspDevPrompt

public QSYSAspDevPrompt(Composite parent,
                        int style,
                        IHost connection)
Constructor

Parameters:
parent - Parent composite
style - The SWT style flags for overall composite widget. Typically just pass SWT.NULL
connection - The connection to limit the user to selecting from.
Method Detail

setAspDevChangeListener

public void setAspDevChangeListener(IQSYSAspDevPromptListener listener)
Identify a caller that is interested in being informed of live error checking status


setDefaultConnection

public void setDefaultConnection(IHost defaultConnection)
Set the default connection to preselect when Browse is pressed. This still allows users to select or create other connections.

Overrides:
setDefaultConnection in class QSYSBasePrompt
See Also:
#setSystemConnection(SystemConnection)

setSystemConnection

public void setSystemConnection(IHost onlyConnection)
Set the system connection to use when Browse is pressed. Unlike setDefaultConnection, this has the result of not allowing the user to select or create any other connection.

See Also:
#setDefaultConnection(SystemConnection)

setPromptLabel

public void setPromptLabel(String label)
Set the prompt label. Default is "Authority" or "Create authority" depending on the mode

Overrides:
setPromptLabel in class QSYSBasePrompt

getAspDevName

public String getAspDevName()
Get the user entered or selected asp dev name. Same as calling QSYSBasePrompt.getText()


setAspDevName

public void setAspDevName(String name)
Set the asp device name or special value displayed in the combo box. Same as calling QSYSBasePrompt.setText(String)


getBrowseAction

protected IIBMiSelectAction getBrowseAction(Shell shell,
                                            IHost defaultConnection,
                                            boolean onlyConnection)
Overridable method. Internal use. Returns action to be called when Browse... pressed.

Specified by:
getBrowseAction in class QSYSBasePrompt

populateCombo

protected void populateCombo(SystemHistoryCombo combo)
Populates the library combo. Internal use.


addOurButtonSelectionListener

protected void addOurButtonSelectionListener()
AspDev's Browse button pressed handler

Overrides:
addOurButtonSelectionListener in class QSYSBasePrompt

validateAspDevInput

public SystemMessage validateAspDevInput()
Validate asp device name, as it is typed, or in batch if you wish to call directly.


isSpecialValue

protected boolean isSpecialValue(String value)
Test if given value is one of the special values...


Rational Developer for Power Systems Software
V7.6

Copyright © 2011 IBM Corp. All Rights Reserved.

Note: This documentation is for part of an interim API that is still under development and expected to change significantly before reaching stability. It is being made available at this early stage to solicit feedback from pioneering adopters on the understanding that any code that uses this API will almost certainly be broken (repeatedly) as the API evolves.