Package org.pentaho.di.ui.trans.step
Class BaseStepXulDialog
- java.lang.Object
-
- org.pentaho.ui.xul.XulEventSourceAdapter
-
- org.pentaho.ui.xul.impl.AbstractXulEventHandler
-
- org.pentaho.di.ui.trans.step.BaseStepGenericXulDialog
-
- org.pentaho.di.ui.trans.step.BaseStepXulDialog
-
- All Implemented Interfaces:
org.pentaho.di.trans.step.StepDialogInterface,org.pentaho.ui.xul.impl.XulEventHandler,org.pentaho.ui.xul.XulEventSource
public abstract class BaseStepXulDialog extends BaseStepGenericXulDialog
User: nbaker Date: Jun 7, 2010
-
-
Field Summary
Fields Modifier and Type Field Description protected booleanbackupChangedprotected static intBUTTON_ALIGNMENT_CENTERprotected static intBUTTON_ALIGNMENT_LEFTprotected static intBUTTON_ALIGNMENT_RIGHTprotected static intbuttonAlignmentprotected booleanchangedprotected DatabaseDialogdatabaseDialogprotected org.eclipse.swt.widgets.ShelldialogShellprotected org.eclipse.swt.widgets.ListenerlsCancelprotected org.eclipse.swt.widgets.ListenerlsCreateprotected org.eclipse.swt.widgets.ListenerlsGetprotected org.eclipse.swt.widgets.ListenerlsOKprotected org.eclipse.swt.widgets.ListenerlsPreviewprotected org.eclipse.swt.widgets.ListenerlsResizeprotected org.eclipse.swt.widgets.ListenerlsSQLprotected PropsUIprops-
Fields inherited from class org.pentaho.di.ui.trans.step.BaseStepGenericXulDialog
baseStepMeta, bf, log, loggingObject, metaStore, parent, repository, stepMeta, stepname, transMeta, variables, wCancel, wCreate, wGet, wlStepname, wOK, wPreview, wSQL, wStepname, xulDialog
-
-
Constructor Summary
Constructors Constructor Description BaseStepXulDialog(String xulFile, org.eclipse.swt.widgets.Shell parent, org.pentaho.di.trans.step.BaseStepMeta baseStepMeta, org.pentaho.di.trans.TransMeta transMeta, String stepname)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description voidclear()Reset this dialog and its controls to a default state.voiddispose()static voidgenerateFieldMapping(org.eclipse.swt.widgets.Shell shell, org.pentaho.di.core.row.RowMetaInterface sourceFields, org.pentaho.di.core.row.RowMetaInterface targetFields, List<org.pentaho.di.core.SourceToTargetMapping> fieldMapping)Create a new field mapping between source and target steps.protected static intgetButtonAlignment()Returns the default alignment for the buttons.protected DatabaseDialoggetDatabaseDialog(org.eclipse.swt.widgets.Shell shell)static voidgetFieldsFromPrevious(org.pentaho.di.core.row.RowMetaInterface row, org.pentaho.ui.xul.containers.XulTree tableView, int keyColumn, int[] nameColumn, int[] dataTypeColumn, int lengthColumn, int precisionColumn, TableItemInsertListener listener)Gets unused fields from previous steps and inserts them as rows into a table view.static voidgetFieldsFromPrevious(org.pentaho.di.core.row.RowMetaInterface row, org.pentaho.ui.xul.containers.XulTree tableView, List<Object> fields, StepTableDataObject field, TableItemInsertXulListener listener)static voidgetFieldsFromPrevious(ComboVar comboVar, org.pentaho.di.trans.TransMeta transMeta, org.pentaho.di.trans.step.StepMeta stepMeta)Gets fields from previous steps and populate a ComboVar.ResourceBundlegetResourceBundle()org.pentaho.ui.xul.XulSettingsManagergetSettingsManager()org.eclipse.swt.widgets.ShellgetShell()protected voidinitializeXul()The implementors of this method should call the sibling method initializeXul(XulLoder, BindingFactory, XulRunner, parent) with the desired Xul implementation classes - SWT or Swing.voidonHelp()voidsetShellImage(org.eclipse.swt.widgets.Shell shell, org.pentaho.di.trans.step.StepMetaInterface stepMetaInterface)voidsetSize()Set the shell size, based upon the previous time the geometry was saved in the Properties file.static voidsetSize(org.eclipse.swt.widgets.Shell shell)static voidsetSize(org.eclipse.swt.widgets.Shell shell, int minWidth, int minHeight, boolean packIt)voidstoreScreenSize()booleanvalidate()-
Methods inherited from class org.pentaho.di.ui.trans.step.BaseStepGenericXulDialog
addDatabases, addDatabases, close, getBindingFactory, getClassForMessages, getEventHandlers, getMetaStore, getName, getPlugin, getRepository, initializeXul, isBasic, isDebug, isDetailed, isRowLevel, logBasic, logBasic, logDebug, logDebug, logDetailed, logDetailed, logError, logError, logError, logMinimal, logMinimal, logRowlevel, logRowlevel, onAccept, onCancel, open, selectDatabase, setMetaStore, setModalParent, setRepository, showClearDataMessage, showMessage, showPromptMessage, showPromptMessage
-
Methods inherited from class org.pentaho.ui.xul.impl.AbstractXulEventHandler
bind, bind, getData, getXulDomContainer, setData, setName, setXulDomContainer
-
-
-
-
Field Detail
-
lsOK
protected org.eclipse.swt.widgets.Listener lsOK
-
lsGet
protected org.eclipse.swt.widgets.Listener lsGet
-
lsPreview
protected org.eclipse.swt.widgets.Listener lsPreview
-
lsSQL
protected org.eclipse.swt.widgets.Listener lsSQL
-
lsCreate
protected org.eclipse.swt.widgets.Listener lsCreate
-
lsCancel
protected org.eclipse.swt.widgets.Listener lsCancel
-
lsResize
protected org.eclipse.swt.widgets.Listener lsResize
-
changed
protected boolean changed
-
backupChanged
protected boolean backupChanged
-
props
protected PropsUI props
-
BUTTON_ALIGNMENT_CENTER
protected static final int BUTTON_ALIGNMENT_CENTER
- See Also:
- Constant Field Values
-
BUTTON_ALIGNMENT_LEFT
protected static final int BUTTON_ALIGNMENT_LEFT
- See Also:
- Constant Field Values
-
BUTTON_ALIGNMENT_RIGHT
protected static final int BUTTON_ALIGNMENT_RIGHT
- See Also:
- Constant Field Values
-
buttonAlignment
protected static int buttonAlignment
-
databaseDialog
protected DatabaseDialog databaseDialog
-
dialogShell
protected org.eclipse.swt.widgets.Shell dialogShell
-
-
Method Detail
-
getSettingsManager
public org.pentaho.ui.xul.XulSettingsManager getSettingsManager()
- Specified by:
getSettingsManagerin classBaseStepGenericXulDialog
-
getResourceBundle
public ResourceBundle getResourceBundle()
- Specified by:
getResourceBundlein classBaseStepGenericXulDialog
-
clear
public void clear()
Description copied from class:BaseStepGenericXulDialogReset this dialog and its controls to a default state.- Specified by:
clearin classBaseStepGenericXulDialog
-
validate
public boolean validate()
- Specified by:
validatein classBaseStepGenericXulDialog
-
initializeXul
protected void initializeXul() throws org.pentaho.ui.xul.XulExceptionDescription copied from class:BaseStepGenericXulDialogThe implementors of this method should call the sibling method initializeXul(XulLoder, BindingFactory, XulRunner, parent) with the desired Xul implementation classes - SWT or Swing.- Specified by:
initializeXulin classBaseStepGenericXulDialog- Throws:
org.pentaho.ui.xul.XulException
-
setShellImage
public void setShellImage(org.eclipse.swt.widgets.Shell shell, org.pentaho.di.trans.step.StepMetaInterface stepMetaInterface)
-
dispose
public void dispose()
- Specified by:
disposein classBaseStepGenericXulDialog
-
getShell
public org.eclipse.swt.widgets.Shell getShell()
-
setSize
public void setSize()
Set the shell size, based upon the previous time the geometry was saved in the Properties file.
-
getButtonAlignment
protected static int getButtonAlignment()
Returns the default alignment for the buttons. This is set in the LAF properties with the keyButton_Position. The valid values are:leftcenterright
centerwill be used as a default- Returns:
- a constant which indicates the button alignment
-
getDatabaseDialog
protected DatabaseDialog getDatabaseDialog(org.eclipse.swt.widgets.Shell shell)
-
storeScreenSize
public void storeScreenSize()
-
setSize
public static void setSize(org.eclipse.swt.widgets.Shell shell)
-
setSize
public static void setSize(org.eclipse.swt.widgets.Shell shell, int minWidth, int minHeight, boolean packIt)
-
getFieldsFromPrevious
public static final void getFieldsFromPrevious(org.pentaho.di.core.row.RowMetaInterface row, org.pentaho.ui.xul.containers.XulTree tableView, int keyColumn, int[] nameColumn, int[] dataTypeColumn, int lengthColumn, int precisionColumn, TableItemInsertListener listener)Gets unused fields from previous steps and inserts them as rows into a table view.- Parameters:
row- the input fieldstableView- the table view to modifykeyColumn- the column in the table view to match with the names of the fields, checks for existance if >0nameColumn- the column numbers in which the name should end up indataTypeColumn- the target column numbers in which the data type should end up inlengthColumn- the length column where the length should end up in (if >0)precisionColumn- the length column where the precision should end up in (if >0)listener- A listener that you can use to do custom modifications to the inserted table item, based on a value from the provided row
-
getFieldsFromPrevious
public static final void getFieldsFromPrevious(ComboVar comboVar, org.pentaho.di.trans.TransMeta transMeta, org.pentaho.di.trans.step.StepMeta stepMeta)
Gets fields from previous steps and populate a ComboVar.- Parameters:
comboVar- the comboVar to populateTransMeta- the source transformationStepMeta- the source step
-
generateFieldMapping
public static final void generateFieldMapping(org.eclipse.swt.widgets.Shell shell, org.pentaho.di.core.row.RowMetaInterface sourceFields, org.pentaho.di.core.row.RowMetaInterface targetFields, List<org.pentaho.di.core.SourceToTargetMapping> fieldMapping) throws org.pentaho.di.core.exception.KettleExceptionCreate a new field mapping between source and target steps.- Parameters:
shell- the shell of the parent windowsourceFields- the source fieldstargetFields- the target fieldsfieldMapping- the list of source to target mappings to default to (can be empty but not null)- Throws:
org.pentaho.di.core.exception.KettleException- in case something goes wrong during the field mapping
-
getFieldsFromPrevious
public static void getFieldsFromPrevious(org.pentaho.di.core.row.RowMetaInterface row, org.pentaho.ui.xul.containers.XulTree tableView, List<Object> fields, StepTableDataObject field, TableItemInsertXulListener listener)
-
onHelp
public void onHelp()
- Overrides:
onHelpin classBaseStepGenericXulDialog
-
-