当前位置: 首页>>代码示例>>Java>>正文


Java EnterTextDialog类代码示例

本文整理汇总了Java中org.pentaho.di.ui.core.dialog.EnterTextDialog的典型用法代码示例。如果您正苦于以下问题:Java EnterTextDialog类的具体用法?Java EnterTextDialog怎么用?Java EnterTextDialog使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。


EnterTextDialog类属于org.pentaho.di.ui.core.dialog包,在下文中一共展示了EnterTextDialog类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: editNote

import org.pentaho.di.ui.core.dialog.EnterTextDialog; //导入依赖的package包/类
protected void editNote(NotePadMeta ni) {
  NotePadMeta before = (NotePadMeta) ni.clone();
  String title = Messages.getString("JobGraph.Dialog.EditNote.Title");
  String message = Messages.getString("JobGraph.Dialog.EditNote.Message");
  EnterTextDialog dd = new EnterTextDialog(shell, title, message, ni.getNote());
  String n = dd.open();
  if (n != null) {
    spoon.addUndoChange(jobMeta, new NotePadMeta[] { before }, new NotePadMeta[] { ni }, new int[] { jobMeta
        .indexOfNote(ni) });
    ni.setChanged();
    ni.setNote(n);
    ni.width = ConstUI.NOTE_MIN_SIZE;
    ni.height = ConstUI.NOTE_MIN_SIZE;
    spoon.refreshGraph();
  }
}
 
开发者ID:icholy,项目名称:geokettle-2.0,代码行数:17,代码来源:JobGraph.java

示例2: editNote

import org.pentaho.di.ui.core.dialog.EnterTextDialog; //导入依赖的package包/类
private void editNote(NotePadMeta ni) {
  NotePadMeta before = (NotePadMeta) ni.clone();

  String title = Messages.getString("TransGraph.Dialog.EditNote.Title"); //$NON-NLS-1$
  String message = Messages.getString("TransGraph.Dialog.EditNote.Message"); //$NON-NLS-1$
  EnterTextDialog dd = new EnterTextDialog(shell, title, message, ni.getNote());
  String n = dd.open();
  if (n != null) {
    ni.setChanged();
    ni.setNote(n);
    ni.width = ConstUI.NOTE_MIN_SIZE;
    ni.height = ConstUI.NOTE_MIN_SIZE;

    NotePadMeta after = (NotePadMeta) ni.clone();
    spoon.addUndoChange(transMeta, new NotePadMeta[] { before }, new NotePadMeta[] { after }, new int[] { transMeta
        .indexOfNote(ni) });
    spoon.refreshGraph();
  }
}
 
开发者ID:icholy,项目名称:geokettle-2.0,代码行数:20,代码来源:TransGraph.java

示例3: view

import org.pentaho.di.ui.core.dialog.EnterTextDialog; //导入依赖的package包/类
private void view()
{
	StringBuffer message=new StringBuffer();
	TableItem item[] = wFields.table.getSelection();
	
	// None selected: don't waste users time: select them all!
	if (item.length==0) item=wFields.table.getItems();
	
	for (int i=0;i<item.length;i++)
	{
		if (i>0)
		    message.append("_______________________________________________________________________________").append(Const.CR).append(Const.CR);
		message.append("[").append(item[i].getText(2)).append("] ").append(item[i].getText(1)).append(Const.CR);
		message.append("  ").append(item[i].getText(3)).append(Const.CR).append(Const.CR);
	}
	
	String subtitle = (item.length != 1 ?
	    Messages.getString("CheckResultDialog.TextDialog.SubtitlePlural") :
	    Messages.getString("CheckResultDialog.TextDialog.Subtitle"));
	EnterTextDialog etd = new EnterTextDialog(shell, Messages.getString("CheckResultDialog.TextDialog.Title"),
	    subtitle, message.toString());
	etd.setReadOnly();
	etd.open();
}
 
开发者ID:icholy,项目名称:geokettle-2.0,代码行数:25,代码来源:CheckResultDialog.java

示例4: pause

import org.pentaho.di.ui.core.dialog.EnterTextDialog; //导入依赖的package包/类
protected void pause() {
  TreeEntry treeEntry = getTreeEntry();
  if (treeEntry == null)
    return;

  // Transformations
  //
  if (treeEntry.isTransformation()) {
    try {
      WebResult webResult = slaveServer.pauseResumeTransformation(treeEntry.name, treeEntry.id);
      if (!webResult.getResult().equalsIgnoreCase(WebResult.STRING_OK)) {
        EnterTextDialog dialog = new EnterTextDialog(shell, BaseMessages.getString(PKG, "SpoonSlave.ErrorPausingOrResumingTrans.Title"),
            BaseMessages.getString(PKG, "SpoonSlave.ErrorPausingOrResumingTrans.Message"), webResult.getMessage());
        dialog.setReadOnly();
        dialog.open();
      }
    } catch (Exception e) {
      new ErrorDialog(shell, BaseMessages.getString(PKG, "SpoonSlave.ErrorPausingOrResumingTrans.Title"), BaseMessages.getString(PKG,
          "SpoonSlave.ErrorPausingOrResumingTrans.Message"), e);
    }
  }
}
 
开发者ID:yintaoxue,项目名称:read-open-source-code,代码行数:23,代码来源:SpoonSlave.java

示例5: pause

import org.pentaho.di.ui.core.dialog.EnterTextDialog; //导入依赖的package包/类
protected void pause() {
  TreeEntry treeEntry = getTreeEntry();
  if ( treeEntry == null ) {
    return;
  }

  if ( treeEntry.isTransformation() ) {
    // Transformation
    try {
      WebResult webResult = slaveServer.pauseResumeTransformation( treeEntry.name, treeEntry.id );
      if ( !WebResult.STRING_OK.equalsIgnoreCase( webResult.getResult() ) ) {
        EnterTextDialog dialog =
          new EnterTextDialog( shell,
            BaseMessages.getString( PKG, "SpoonSlave.ErrorPausingOrResumingTrans.Title" ),
            BaseMessages.getString( PKG, "SpoonSlave.ErrorPausingOrResumingTrans.Message" ),
            webResult.getMessage() );
        dialog.setReadOnly();
        dialog.open();
      }
    } catch ( Exception e ) {
      new ErrorDialog( shell,
        BaseMessages.getString( PKG, "SpoonSlave.ErrorPausingOrResumingTrans.Title" ),
        BaseMessages.getString( PKG, "SpoonSlave.ErrorPausingOrResumingTrans.Message" ), e );
    }
  }
}
 
开发者ID:pentaho,项目名称:pentaho-kettle,代码行数:27,代码来源:SpoonSlave.java

示例6: preview

import org.pentaho.di.ui.core.dialog.EnterTextDialog; //导入依赖的package包/类
private void preview() {
    CassandraInputMeta oneMeta = new CassandraInputMeta();
    getInfo(oneMeta, true);

    TransMeta previewMeta = TransPreviewFactory.generatePreviewTransformation(this.transMeta, oneMeta, this.wStepname.getText());

    EnterNumberDialog numberDialog = new EnterNumberDialog(this.shell, this.props.getDefaultPreviewSize(),
            BaseMessages.getString(PKG, "AutSoftCassandraInputDialog.EnterPreviewSize"),
            BaseMessages.getString(PKG, "AutSoftCassandraInputDialog.NumberOfRowsToPreview"));
    int previewSize = numberDialog.open();

    if (previewSize > 0) {
        TransPreviewProgressDialog progressDialog = new TransPreviewProgressDialog(this.shell, previewMeta,
                new String[]{this.wStepname.getText()}, new int[]{previewSize});
        progressDialog.open();

        Trans trans = progressDialog.getTrans();
        String loggingText = progressDialog.getLoggingText();

        if (!progressDialog.isCancelled()) {
            if ((trans.getResult() != null) && (trans.getResult().getNrErrors() > 0L)) {
                EnterTextDialog etd = new EnterTextDialog(this.shell,
                        BaseMessages.getString(PKG, "System.Dialog.PreviewError.Title"),
                        BaseMessages.getString(PKG, "System.Dialog.PreviewError.Message"), loggingText, true);
                etd.setReadOnly();
                etd.open();
            } else {
                PreviewRowsDialog prd = new PreviewRowsDialog(this.shell, this.transMeta, 0, this.wStepname.getText(),
                        progressDialog.getPreviewRowsMeta(this.wStepname.getText()),
                        progressDialog.getPreviewRows(this.wStepname.getText()), loggingText);
                prd.open();
            }
        }
    }
}
 
开发者ID:bcolas,项目名称:pentaho-cassandra-plugin,代码行数:36,代码来源:CassandraInputDialog.java

示例7: preview

import org.pentaho.di.ui.core.dialog.EnterTextDialog; //导入依赖的package包/类
private void preview()
{
	// Create the XML input step
	GetSubFoldersMeta oneMeta = new GetSubFoldersMeta();
	getInfo(oneMeta);

	TransMeta previewMeta = TransPreviewFactory.generatePreviewTransformation(transMeta, oneMeta, wStepname
			.getText());

	EnterNumberDialog numberDialog = new EnterNumberDialog(shell, props.getDefaultPreviewSize(), Messages.getString("GetSubFoldersDialog.PreviewSize.DialogTitle"), Messages.getString("GetSubFoldersDialog.PreviewSize.DialogMessage"));
	int previewSize = numberDialog.open();
	if (previewSize > 0)
	{
		TransPreviewProgressDialog progressDialog = new TransPreviewProgressDialog(shell, previewMeta,
				new String[] { wStepname.getText() }, new int[] { previewSize });
		progressDialog.open();

		if (!progressDialog.isCancelled())
		{
			Trans trans = progressDialog.getTrans();
			String loggingText = progressDialog.getLoggingText();

			if (trans.getResult() != null && trans.getResult().getNrErrors() > 0)
			{
				EnterTextDialog etd = new EnterTextDialog(shell, Messages.getString("System.Dialog.Error.Title"), Messages.getString("GetSubFoldersDialog.ErrorInPreview.DialogMessage"), loggingText, true);
				etd.setReadOnly();
				etd.open();
			}
			
			
			PreviewRowsDialog prd = new PreviewRowsDialog(shell, transMeta, SWT.NONE, wStepname.getText(),progressDialog.getPreviewRowsMeta(wStepname.getText()),
					progressDialog.getPreviewRows(wStepname.getText()), loggingText);
			prd.open();
		}
	}
}
 
开发者ID:icholy,项目名称:geokettle-2.0,代码行数:37,代码来源:GetSubFoldersDialog.java

示例8: preview

import org.pentaho.di.ui.core.dialog.EnterTextDialog; //导入依赖的package包/类
private void preview()
{
	// execute a complete preview transformation in the background.
	// This is how we do it...
	//
    FixedInputMeta oneMeta = new FixedInputMeta();
    getInfo(oneMeta);
    
    TransMeta previewMeta = TransPreviewFactory.generatePreviewTransformation(transMeta, oneMeta, wStepname.getText());
    
    EnterNumberDialog numberDialog = new EnterNumberDialog(shell, props.getDefaultPreviewSize(), Messages.getString("FixedInputDialog.PreviewSize.DialogTitle"), Messages.getString("FixedInputDialog.PreviewSize.DialogMessage"));
    int previewSize = numberDialog.open();
    if (previewSize>0)
    {
        TransPreviewProgressDialog progressDialog = new TransPreviewProgressDialog(shell, previewMeta, new String[] { wStepname.getText() }, new int[] { previewSize } );
        progressDialog.open();

        Trans trans = progressDialog.getTrans();
        String loggingText = progressDialog.getLoggingText();

        if (!progressDialog.isCancelled())
        {
            if (trans.getResult()!=null && trans.getResult().getNrErrors()>0)
            {
            	EnterTextDialog etd = new EnterTextDialog(shell, Messages.getString("System.Dialog.PreviewError.Title"),  
            			Messages.getString("System.Dialog.PreviewError.Message"), loggingText, true );
            	etd.setReadOnly();
            	etd.open();
            }
        }
        
        PreviewRowsDialog prd =new PreviewRowsDialog(shell, transMeta, SWT.NONE, wStepname.getText(), progressDialog.getPreviewRowsMeta(wStepname.getText()), progressDialog.getPreviewRows(wStepname.getText()), loggingText);
        prd.open();
    }
}
 
开发者ID:icholy,项目名称:geokettle-2.0,代码行数:36,代码来源:FixedInputDialog.java

示例9: preview

import org.pentaho.di.ui.core.dialog.EnterTextDialog; //导入依赖的package包/类
private void preview()
{
	// Create the XML input step
	GetFileNamesMeta oneMeta = new GetFileNamesMeta();
	getInfo(oneMeta);

	TransMeta previewMeta = TransPreviewFactory.generatePreviewTransformation(transMeta, oneMeta, wStepname
			.getText());

	EnterNumberDialog numberDialog = new EnterNumberDialog(shell, props.getDefaultPreviewSize(), Messages.getString("GetFileNamesDialog.PreviewSize.DialogTitle"), Messages.getString("GetFileNamesDialog.PreviewSize.DialogMessage"));
	int previewSize = numberDialog.open();
	if (previewSize > 0)
	{
		TransPreviewProgressDialog progressDialog = new TransPreviewProgressDialog(shell, previewMeta,
				new String[] { wStepname.getText() }, new int[] { previewSize });
		progressDialog.open();

		if (!progressDialog.isCancelled())
		{
			Trans trans = progressDialog.getTrans();
			String loggingText = progressDialog.getLoggingText();

			if (trans.getResult() != null && trans.getResult().getNrErrors() > 0)
			{
				EnterTextDialog etd = new EnterTextDialog(shell, Messages.getString("System.Dialog.Error.Title"), Messages.getString("GetFileNamesDialog.ErrorInPreview.DialogMessage"), loggingText, true);
				etd.setReadOnly();
				etd.open();
			}
			
			
			PreviewRowsDialog prd = new PreviewRowsDialog(shell, transMeta, SWT.NONE, wStepname.getText(),progressDialog.getPreviewRowsMeta(wStepname.getText()),
					progressDialog.getPreviewRows(wStepname.getText()), loggingText);
			prd.open();
		}
	}
}
 
开发者ID:icholy,项目名称:geokettle-2.0,代码行数:37,代码来源:GetFileNamesDialog.java

示例10: preview

import org.pentaho.di.ui.core.dialog.EnterTextDialog; //导入依赖的package包/类
private void preview()
{
    // Create the XML input step
	ParGzipCsvInputMeta oneMeta = new ParGzipCsvInputMeta();
    getInfo(oneMeta);
    
    TransMeta previewMeta = TransPreviewFactory.generatePreviewTransformation(transMeta, oneMeta, wStepname.getText());
    
    EnterNumberDialog numberDialog = new EnterNumberDialog(shell, props.getDefaultPreviewSize(), Messages.getString("ParGzipCsvInputDialog.PreviewSize.DialogTitle"), Messages.getString("ParGzipCsvInputDialog.PreviewSize.DialogMessage"));
    int previewSize = numberDialog.open();
    if (previewSize>0)
    {
        TransPreviewProgressDialog progressDialog = new TransPreviewProgressDialog(shell, previewMeta, new String[] { wStepname.getText() }, new int[] { previewSize } );
        progressDialog.open();

        Trans trans = progressDialog.getTrans();
        String loggingText = progressDialog.getLoggingText();

        if (!progressDialog.isCancelled())
        {
            if (trans.getResult()!=null && trans.getResult().getNrErrors()>0)
            {
            	EnterTextDialog etd = new EnterTextDialog(shell, Messages.getString("System.Dialog.PreviewError.Title"),  
            			Messages.getString("System.Dialog.PreviewError.Message"), loggingText, true );
            	etd.setReadOnly();
            	etd.open();
            }
        }
        
        PreviewRowsDialog prd =new PreviewRowsDialog(shell, transMeta, SWT.NONE, wStepname.getText(), progressDialog.getPreviewRowsMeta(wStepname.getText()), progressDialog.getPreviewRows(wStepname.getText()), loggingText);
        prd.open();
    }
}
 
开发者ID:icholy,项目名称:geokettle-2.0,代码行数:34,代码来源:ParGzipCsvInputDialog.java

示例11: preview

import org.pentaho.di.ui.core.dialog.EnterTextDialog; //导入依赖的package包/类
/**
 * Preview the data generated by this step.
 * This generates a transformation using this step & a dummy and previews it.
 *
 */
private void preview()
{
    // Create the table input reader step...
    TableInputMeta oneMeta = new TableInputMeta();
    getInfo(oneMeta);
    
    TransMeta previewMeta = TransPreviewFactory.generatePreviewTransformation(transMeta, oneMeta, wStepname.getText());
    
    EnterNumberDialog numberDialog = new EnterNumberDialog(shell, props.getDefaultPreviewSize(), Messages.getString("TableInputDialog.EnterPreviewSize"), Messages.getString("TableInputDialog.NumberOfRowsToPreview")); //$NON-NLS-1$ //$NON-NLS-2$
    int previewSize = numberDialog.open();
    if (previewSize>0)
    {
        TransPreviewProgressDialog progressDialog = new TransPreviewProgressDialog(shell, previewMeta, new String[] { wStepname.getText() }, new int[] { previewSize } );
        progressDialog.open();

        Trans trans = progressDialog.getTrans();
        String loggingText = progressDialog.getLoggingText();

        if (!progressDialog.isCancelled())
        {
            if (trans.getResult()!=null && trans.getResult().getNrErrors()>0)
            {
            	EnterTextDialog etd = new EnterTextDialog(shell, Messages.getString("System.Dialog.PreviewError.Title"),  
            			Messages.getString("System.Dialog.PreviewError.Message"), loggingText, true );
            	etd.setReadOnly();
            	etd.open();
            }
        }
        
        PreviewRowsDialog prd =new PreviewRowsDialog(shell, transMeta, SWT.NONE, wStepname.getText(), progressDialog.getPreviewRowsMeta(wStepname.getText()), progressDialog.getPreviewRows(wStepname.getText()), loggingText);
        prd.open();
    }
}
 
开发者ID:icholy,项目名称:geokettle-2.0,代码行数:39,代码来源:TableInputDialog.java

示例12: preview

import org.pentaho.di.ui.core.dialog.EnterTextDialog; //导入依赖的package包/类
/**
 * Preview the data generated by this step.
 * This generates a transformation using this step & a dummy and previews it.
 *
 */
private void preview()
{
    // Create the table input reader step...
    MondrianInputMeta oneMeta = new MondrianInputMeta();
    getInfo(oneMeta);
    
    TransMeta previewMeta = TransPreviewFactory.generatePreviewTransformation(transMeta, oneMeta, wStepname.getText());
    
    EnterNumberDialog numberDialog = new EnterNumberDialog(shell, props.getDefaultPreviewSize(), Messages.getString("MondrianInputDialog.EnterPreviewSize"), Messages.getString("MondrianInputDialog.NumberOfRowsToPreview")); //$NON-NLS-1$ //$NON-NLS-2$
    int previewSize = numberDialog.open();
    if (previewSize>0)
    {
        TransPreviewProgressDialog progressDialog = new TransPreviewProgressDialog(shell, previewMeta, new String[] { wStepname.getText() }, new int[] { previewSize } );
        progressDialog.open();

        Trans trans = progressDialog.getTrans();
        String loggingText = progressDialog.getLoggingText();

        if (!progressDialog.isCancelled())
        {
            if (trans.getResult()!=null && trans.getResult().getNrErrors()>0)
            {
            	EnterTextDialog etd = new EnterTextDialog(shell, Messages.getString("System.Dialog.PreviewError.Title"),  
            			Messages.getString("System.Dialog.PreviewError.Message"), loggingText, true );
            	etd.setReadOnly();
            	etd.open();
            }
        }
        
        PreviewRowsDialog prd =new PreviewRowsDialog(shell, transMeta, SWT.NONE, wStepname.getText(), progressDialog.getPreviewRowsMeta(wStepname.getText()), progressDialog.getPreviewRows(wStepname.getText()), loggingText);
        prd.open();
    }
}
 
开发者ID:icholy,项目名称:geokettle-2.0,代码行数:39,代码来源:MondrianInputDialog.java

示例13: preview

import org.pentaho.di.ui.core.dialog.EnterTextDialog; //导入依赖的package包/类
private void preview()
{
    // Create the XML input step
    CsvInputMeta oneMeta = new CsvInputMeta();
    getInfo(oneMeta);
    
    TransMeta previewMeta = TransPreviewFactory.generatePreviewTransformation(transMeta, oneMeta, wStepname.getText());
    
    EnterNumberDialog numberDialog = new EnterNumberDialog(shell, props.getDefaultPreviewSize(), Messages.getString("CsvInputDialog.PreviewSize.DialogTitle"), Messages.getString("CsvInputDialog.PreviewSize.DialogMessage"));
    int previewSize = numberDialog.open();
    if (previewSize>0)
    {
        TransPreviewProgressDialog progressDialog = new TransPreviewProgressDialog(shell, previewMeta, new String[] { wStepname.getText() }, new int[] { previewSize } );
        progressDialog.open();

        Trans trans = progressDialog.getTrans();
        String loggingText = progressDialog.getLoggingText();

        if (!progressDialog.isCancelled())
        {
            if (trans.getResult()!=null && trans.getResult().getNrErrors()>0)
            {
            	EnterTextDialog etd = new EnterTextDialog(shell, Messages.getString("System.Dialog.PreviewError.Title"),  
            			Messages.getString("System.Dialog.PreviewError.Message"), loggingText, true );
            	etd.setReadOnly();
            	etd.open();
            }
        }
        
        PreviewRowsDialog prd =new PreviewRowsDialog(shell, transMeta, SWT.NONE, wStepname.getText(), progressDialog.getPreviewRowsMeta(wStepname.getText()), progressDialog.getPreviewRows(wStepname.getText()), loggingText);
        prd.open();
    }
}
 
开发者ID:icholy,项目名称:geokettle-2.0,代码行数:34,代码来源:CsvInputDialog.java

示例14: editEntryDescription

import org.pentaho.di.ui.core.dialog.EnterTextDialog; //导入依赖的package包/类
public void editEntryDescription() {
  String title = Messages.getString("JobGraph.Dialog.EditDescription.Title"); //$NON-NLS-1$
  String message = Messages.getString("JobGraph.Dialog.EditDescription.Message"); //$NON-NLS-1$
  EnterTextDialog dd = new EnterTextDialog(shell, title, message, getJobEntry().getDescription());
  String des = dd.open();
  if (des != null)
    jobEntry.setDescription(des);
}
 
开发者ID:icholy,项目名称:geokettle-2.0,代码行数:9,代码来源:JobGraph.java

示例15: newNote

import org.pentaho.di.ui.core.dialog.EnterTextDialog; //导入依赖的package包/类
public void newNote() {
  selrect = null;
  String title = Messages.getString("JobGraph.Dialog.EditNote.Title");
  String message = Messages.getString("JobGraph.Dialog.EditNote.Message");
  EnterTextDialog dd = new EnterTextDialog(shell, title, message, "");
  String n = dd.open();
  if (n != null) {
    NotePadMeta npi = new NotePadMeta(n, lastclick.x, lastclick.y, ConstUI.NOTE_MIN_SIZE, ConstUI.NOTE_MIN_SIZE);
    jobMeta.addNote(npi);
    spoon.addUndoNew(jobMeta, new NotePadMeta[] { npi }, new int[] { jobMeta.indexOfNote(npi) });
    redraw();
  }
}
 
开发者ID:icholy,项目名称:geokettle-2.0,代码行数:14,代码来源:JobGraph.java


注:本文中的org.pentaho.di.ui.core.dialog.EnterTextDialog类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。