Class ConditionSelectionAdapterFileDialogTextVar
java.lang.Object
org.eclipse.swt.events.SelectionAdapter
org.pentaho.di.ui.core.events.dialog.SelectionAdapterFileDialog<TextVar>
org.pentaho.di.ui.core.events.dialog.SelectionAdapterFileDialogTextVar
org.pentaho.di.ui.core.events.dialog.ConditionSelectionAdapterFileDialogTextVar
- All Implemented Interfaces:
EventListener
,org.eclipse.swt.events.SelectionListener
,org.eclipse.swt.internal.SWTEventListener
This Adapter class extends the SelectionAdapterFileDialogTextVar but includes (DetermineSelectionOperationOp) Interface to
allow the dialog to determine which SelectionOperation (File or Folder) when the widget is selected. This is useful
for steps that include "File Or Directory" option based on the dialog settings.
Example:
SelectionAdapterOptions options = new SelectionAdapterOptions( SelectionOperation.FILE,
new FilterType[] { FilterType.ALL, FilterType.XML }, FilterType.XML );
adapter = new ConditionSelectionAdapterFileDialogTextVar( log, wFilename, transMeta, options,
() -> ( [ Is Folder Condition ] ) ? SelectionOperation.FOLDER : SelectionOperation.FILE );
Note:
The class only updates SelectionOperation to Folder the other options remain the same.
-
Constructor Summary
ConstructorDescriptionConditionSelectionAdapterFileDialogTextVar
(org.pentaho.di.core.logging.LogChannelInterface log, TextVar textUiWidget, org.pentaho.di.base.AbstractMeta meta, SelectionAdapterOptions options, DetermineSelectionOperationOp operator) -
Method Summary
Modifier and TypeMethodDescriptionvoid
widgetSelected
(org.eclipse.swt.events.SelectionEvent selectionEvent) Methods inherited from class org.pentaho.di.ui.core.events.dialog.SelectionAdapterFileDialogTextVar
getText, setText
Methods inherited from class org.pentaho.di.ui.core.events.dialog.SelectionAdapterFileDialog
concat, getSelectionOptions, getTextWidget, isConnectionFile, isUrl, resolveFile, setFilter
Methods inherited from class org.eclipse.swt.events.SelectionAdapter
widgetDefaultSelected
-
Constructor Details
-
ConditionSelectionAdapterFileDialogTextVar
public ConditionSelectionAdapterFileDialogTextVar(org.pentaho.di.core.logging.LogChannelInterface log, TextVar textUiWidget, org.pentaho.di.base.AbstractMeta meta, SelectionAdapterOptions options, DetermineSelectionOperationOp operator)
-
-
Method Details
-
widgetSelected
public void widgetSelected(org.eclipse.swt.events.SelectionEvent selectionEvent) - Specified by:
widgetSelected
in interfaceorg.eclipse.swt.events.SelectionListener
- Overrides:
widgetSelected
in classSelectionAdapterFileDialog<TextVar>
-