Class CsvInputDialog
- java.lang.Object
-
- org.eclipse.swt.widgets.Dialog
-
- org.pentaho.di.ui.trans.step.BaseStepDialog
-
- org.pentaho.di.ui.trans.steps.csvinput.CsvInputDialog
-
- All Implemented Interfaces:
org.pentaho.di.trans.step.StepDialogInterface,CsvInputAwareStepDialog,GetFieldsCapableStepDialog<org.pentaho.di.trans.steps.csvinput.CsvInputMeta>
public class CsvInputDialog extends BaseStepDialog implements org.pentaho.di.trans.step.StepDialogInterface, GetFieldsCapableStepDialog<org.pentaho.di.trans.steps.csvinput.CsvInputMeta>, CsvInputAwareStepDialog
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class org.pentaho.di.ui.trans.step.BaseStepDialog
BaseStepDialog.AddConnectionListener, BaseStepDialog.EditConnectionListener, BaseStepDialog.FieldsChoiceDialogProvider
-
-
Field Summary
-
Fields inherited from class org.pentaho.di.ui.trans.step.BaseStepDialog
backupChanged, baseStepMeta, BUTTON_ALIGNMENT_CENTER, BUTTON_ALIGNMENT_LEFT, BUTTON_ALIGNMENT_RIGHT, buttonAlignment, changed, databaseDialog, fdCancel, fdCreate, fdGet, fdlStepname, fdOK, fdPreview, fdSQL, fdStepname, log, loggingObject, lsCancel, lsCreate, lsDef, lsGet, lsOK, lsPreview, lsResize, lsSQL, metaStore, props, repository, shell, stepMeta, stepname, transMeta, variables, wCancel, wCreate, wGet, wlStepname, wOK, wPreview, wSQL, wStepname
-
Fields inherited from interface org.pentaho.di.ui.trans.step.common.GetFieldsCapableStepDialog
logger
-
-
Constructor Summary
Constructors Constructor Description CsvInputDialog(org.eclipse.swt.widgets.Shell parent, Object in, org.pentaho.di.trans.TransMeta tr, String sname)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected voidasyncUpdatePreview()CsvInputAwareImportProgressDialoggetCsvImportProgressDialog(org.pentaho.di.trans.steps.common.CsvInputAwareMeta meta, int samples, InputStreamReader reader)voidgetData()voidgetData(org.pentaho.di.trans.steps.csvinput.CsvInputMeta inputMeta, boolean copyStepname)Copy information from the meta-data input to the dialog fields.voidgetData(org.pentaho.di.trans.steps.csvinput.CsvInputMeta inputMeta, boolean copyStepname, boolean reloadAllFields, Set<String> newFieldNames)String[]getFieldNames(org.pentaho.di.trans.steps.csvinput.CsvInputMeta meta)Returns an array of incoming field names, or an empty array, if fields cannot be fetched, for some reason.TableViewgetFieldsTable()InputStreamgetInputStream(org.pentaho.di.trans.steps.common.CsvInputAwareMeta meta)Returns theInputStreamcorresponding to the csv file, or null if the file cannot be read.org.pentaho.di.core.logging.LogChannelgetLogChannel()org.pentaho.di.trans.steps.csvinput.CsvInputMetagetNewMetaInstance()org.eclipse.swt.widgets.ShellgetShell()Returns theShellof this dialog.org.pentaho.di.trans.TransMetagetTransMeta()StringloadFieldsImpl(org.pentaho.di.trans.steps.csvinput.CsvInputMeta meta, int samples)Stringopen()voidpopulateMeta(org.pentaho.di.trans.steps.csvinput.CsvInputMeta inputMeta)protected voidsetFlags()protected voidupdatePreview()Load metadata from step window-
Methods inherited from class org.pentaho.di.ui.trans.step.BaseStepDialog
addConnectionLine, addConnectionLine, addConnectionLine, addConnectionLine, addDatabases, addDatabases, centerButtons, createHelpButton, dispose, generateFieldMapping, getButtonAlignment, getDatabaseDialog, getFieldsFromPrevious, getFieldsFromPrevious, getFieldsFromPrevious, getFieldsFromPrevious, getFieldsFromPrevious, getMetaStore, getModifyListenerTooltipText, getPathOf, getRepository, isBasic, isDebug, isDetailed, isRowLevel, leftAlignButtons, logBasic, logBasic, logDebug, logDebug, logDetailed, logDetailed, logError, logError, logError, logMinimal, logMinimal, logRowlevel, logRowlevel, positionBottomButtons, positionBottomButtons, positionBottomLeftButtons, positionBottomRightButtons, reinitConnectionDropDown, rightAlignButtons, selectDatabase, setButtonPositions, setMetaStore, setMinimalShellHeight, setRepository, setShellImage, setSize, setSize, setSize, setSize, setTraverseOrder, showDbDialogUnlessCancelledOrValid, showDbExistsDialog, storeScreenSize, toString
-
Methods inherited from class org.eclipse.swt.widgets.Dialog
checkSubclass, getParent, getStyle, getText, setText
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface org.pentaho.di.ui.trans.step.common.CsvInputAwareStepDialog
getBufferedReader, getFieldNames, getFieldNamesImpl, getReader, loadFieldsImpl, logError, logError, massageFieldName
-
Methods inherited from interface org.pentaho.di.ui.trans.step.common.GetFieldsCapableStepDialog
findTableItem, getFields, getFields, getFieldValues, getNewFieldNames, getParent, getPopulatedMeta, getTableItem, getTableItem, loadFields, loadRemainingFields, openGetFieldsSampleDataDialog, repopulateFields
-
-
-
-
Method Detail
-
open
public String open()
- Specified by:
openin interfaceorg.pentaho.di.trans.step.StepDialogInterface
-
setFlags
protected void setFlags()
-
getNewMetaInstance
public org.pentaho.di.trans.steps.csvinput.CsvInputMeta getNewMetaInstance()
- Specified by:
getNewMetaInstancein interfaceGetFieldsCapableStepDialog<org.pentaho.di.trans.steps.csvinput.CsvInputMeta>
-
populateMeta
public void populateMeta(org.pentaho.di.trans.steps.csvinput.CsvInputMeta inputMeta)
- Specified by:
populateMetain interfaceGetFieldsCapableStepDialog<org.pentaho.di.trans.steps.csvinput.CsvInputMeta>
-
getData
public void getData()
-
getData
public void getData(org.pentaho.di.trans.steps.csvinput.CsvInputMeta inputMeta, boolean copyStepname)Copy information from the meta-data input to the dialog fields.
-
getData
public void getData(org.pentaho.di.trans.steps.csvinput.CsvInputMeta inputMeta, boolean copyStepname, boolean reloadAllFields, Set<String> newFieldNames)- Specified by:
getDatain interfaceGetFieldsCapableStepDialog<org.pentaho.di.trans.steps.csvinput.CsvInputMeta>
-
getFieldNames
public String[] getFieldNames(org.pentaho.di.trans.steps.csvinput.CsvInputMeta meta)
Description copied from interface:GetFieldsCapableStepDialogReturns an array of incoming field names, or an empty array, if fields cannot be fetched, for some reason.- Specified by:
getFieldNamesin interfaceGetFieldsCapableStepDialog<org.pentaho.di.trans.steps.csvinput.CsvInputMeta>- Parameters:
meta- theGetFieldsCapableStepDialog- Returns:
- an array of incoming field names, or an empty array, if fields cannot be fetched, for some reason.
-
getFieldsTable
public TableView getFieldsTable()
- Specified by:
getFieldsTablein interfaceGetFieldsCapableStepDialog<org.pentaho.di.trans.steps.csvinput.CsvInputMeta>- Returns:
- the
TableViewcontaining step fields
-
loadFieldsImpl
public String loadFieldsImpl(org.pentaho.di.trans.steps.csvinput.CsvInputMeta meta, int samples)
- Specified by:
loadFieldsImplin interfaceGetFieldsCapableStepDialog<org.pentaho.di.trans.steps.csvinput.CsvInputMeta>
-
updatePreview
protected void updatePreview()
Load metadata from step window
-
asyncUpdatePreview
protected void asyncUpdatePreview()
-
getShell
public org.eclipse.swt.widgets.Shell getShell()
Description copied from interface:GetFieldsCapableStepDialogReturns theShellof this dialog.- Specified by:
getShellin interfaceGetFieldsCapableStepDialog<org.pentaho.di.trans.steps.csvinput.CsvInputMeta>- Returns:
- the
Shellof this dialog
-
getCsvImportProgressDialog
public CsvInputAwareImportProgressDialog getCsvImportProgressDialog(org.pentaho.di.trans.steps.common.CsvInputAwareMeta meta, int samples, InputStreamReader reader)
- Specified by:
getCsvImportProgressDialogin interfaceCsvInputAwareStepDialog
-
getLogChannel
public org.pentaho.di.core.logging.LogChannel getLogChannel()
- Specified by:
getLogChannelin interfaceCsvInputAwareStepDialog
-
getTransMeta
public org.pentaho.di.trans.TransMeta getTransMeta()
- Specified by:
getTransMetain interfaceCsvInputAwareStepDialog- Specified by:
getTransMetain interfaceGetFieldsCapableStepDialog<org.pentaho.di.trans.steps.csvinput.CsvInputMeta>
-
getInputStream
public InputStream getInputStream(org.pentaho.di.trans.steps.common.CsvInputAwareMeta meta)
Description copied from interface:CsvInputAwareStepDialogReturns theInputStreamcorresponding to the csv file, or null if the file cannot be read.- Specified by:
getInputStreamin interfaceCsvInputAwareStepDialog- Returns:
- the
InputStreamcorresponding to the csv file, or null if the file cannot be read
-
-