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


Java JobDialog类代码示例

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


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

示例1: editProperties

import org.pentaho.di.ui.job.dialog.JobDialog; //导入依赖的package包/类
public static boolean editProperties(JobMeta jobMeta, Spoon spoon, Repository rep, boolean allowDirectoryChange) {
  if (jobMeta == null)
    return false;

  JobDialog jd = new JobDialog(spoon.getShell(), SWT.NONE, jobMeta, rep);
  jd.setDirectoryChangeAllowed(allowDirectoryChange);
  JobMeta ji = jd.open();

  // In this case, load shared objects
  //
  if (jd.isSharedObjectsFileChanged()) {
    try {
      SharedObjects sharedObjects = jobMeta.readSharedObjects(rep);
      spoon.sharedObjectsFileMap.put(sharedObjects.getFilename(), sharedObjects);
    } catch (Exception e) {
      new ErrorDialog(spoon.getShell(), Messages.getString("Spoon.Dialog.ErrorReadingSharedObjects.Title"), 
      		Messages.getString("Spoon.Dialog.ErrorReadingSharedObjects.Message", spoon.delegates.tabs
              .makeJobGraphTabName(jobMeta)), e);
    }
  }
  
  // If we added properties, add them to the variables too, so that they appear in the CTRL-SPACE variable completion.
  //
  spoon.setParametersAsVariablesInUI(jobMeta, jobMeta);

  if (jd.isSharedObjectsFileChanged() || ji != null) {
    spoon.refreshTree();
    spoon.delegates.tabs.renameTabs(); // cheap operation, might as will do it anyway
  }

  spoon.setShellText();
  return ji != null;
}
 
开发者ID:icholy,项目名称:geokettle-2.0,代码行数:34,代码来源:JobGraph.java

示例2: editProperties

import org.pentaho.di.ui.job.dialog.JobDialog; //导入依赖的package包/类
public static boolean editProperties(JobMeta jobMeta, Spoon spoon, Repository rep, boolean allowDirectoryChange) {
  if (jobMeta == null)
    return false;

  JobDialog jd = new JobDialog(spoon.getShell(), SWT.NONE, jobMeta, rep);
  jd.setDirectoryChangeAllowed(allowDirectoryChange);
  JobMeta ji = jd.open();

  // In this case, load shared objects
  //
  if (jd.isSharedObjectsFileChanged()) {
    try {
      SharedObjects sharedObjects = rep!=null ? rep.readJobMetaSharedObjects(jobMeta) : jobMeta.readSharedObjects();
      spoon.sharedObjectsFileMap.put(sharedObjects.getFilename(), sharedObjects);
    } catch (Exception e) {
      new ErrorDialog(spoon.getShell(), BaseMessages.getString(PKG, "Spoon.Dialog.ErrorReadingSharedObjects.Title"), 
      		BaseMessages.getString(PKG, "Spoon.Dialog.ErrorReadingSharedObjects.Message", spoon.delegates.tabs.makeTabName(jobMeta, true)), e);
    }
  }
  
  // If we added properties, add them to the variables too, so that they appear in the CTRL-SPACE variable completion.
  //
  spoon.setParametersAsVariablesInUI(jobMeta, jobMeta);

  if (jd.isSharedObjectsFileChanged() || ji != null) {
    spoon.refreshTree();
    spoon.delegates.tabs.renameTabs(); // cheap operation, might as will do it anyway
  }

  spoon.setShellText();
  return ji != null;
}
 
开发者ID:yintaoxue,项目名称:read-open-source-code,代码行数:33,代码来源:JobGraph.java

示例3: open

import org.pentaho.di.ui.job.dialog.JobDialog; //导入依赖的package包/类
public JobEntryInterface open() {
  Shell parent = getParent();
  display = parent.getDisplay();

  shell = new Shell( parent, props.getJobsDialogStyle() );
  props.setLook( shell );
  JobDialog.setShellImage( shell, jobEntry );

  backupChanged = jobEntry.hasChanged();

  createElements();

  // Detect [X] or ALT-F4 or something that kills this window...
  shell.addShellListener( new ShellAdapter() {
    public void shellClosed( ShellEvent e ) {
      cancel();
    }
  } );

  getData();
  setActive();

  BaseStepDialog.setSize( shell );

  int width = 750;
  int height = Const.isWindows() ? 730 : 718;

  shell.setSize( width, height );
  shell.open();
  while ( !shell.isDisposed() ) {
    if ( !display.readAndDispatch() ) {
      display.sleep();
    }
  }
  return jobEntry;
}
 
开发者ID:pentaho,项目名称:pentaho-kettle,代码行数:37,代码来源:JobEntryJobDialog.java

示例4: open

import org.pentaho.di.ui.job.dialog.JobDialog; //导入依赖的package包/类
public JobEntryInterface open() {
  Shell parent = getParent();
  display = parent.getDisplay();

  shell = new Shell( parent, props.getJobsDialogStyle() );
  props.setLook( shell );
  JobDialog.setShellImage( shell, jobEntry );

  backupChanged = jobEntry.hasChanged();

  createElements();

  // Detect [X] or ALT-F4 or something that kills this window...
  shell.addShellListener( new ShellAdapter() {
    public void shellClosed( ShellEvent e ) {
      cancel();
    }
  } );

  getData();
  setActive();

  BaseStepDialog.setSize( shell );

  int width = 750;
  int height = Const.isWindows() ? 730 : 720;

  shell.setSize( width, height );
  shell.open();
  while ( !shell.isDisposed() ) {
    if ( !display.readAndDispatch() ) {
      display.sleep();
    }
  }
  return jobEntry;
}
 
开发者ID:pentaho,项目名称:pentaho-kettle,代码行数:37,代码来源:JobEntryTransDialog.java

示例5: editProperties

import org.pentaho.di.ui.job.dialog.JobDialog; //导入依赖的package包/类
public static boolean editProperties( JobMeta jobMeta, Spoon spoon, Repository rep, boolean allowDirectoryChange ) {
  if ( jobMeta == null ) {
    return false;
  }

  JobDialog jd = new JobDialog( spoon.getShell(), SWT.NONE, jobMeta, rep );
  jd.setDirectoryChangeAllowed( allowDirectoryChange );
  JobMeta ji = jd.open();

  // In this case, load shared objects
  //
  if ( jd.isSharedObjectsFileChanged() ) {
    try {
      SharedObjects sharedObjects =
        rep != null ? rep.readJobMetaSharedObjects( jobMeta ) : jobMeta.readSharedObjects();
      spoon.sharedObjectsFileMap.put( sharedObjects.getFilename(), sharedObjects );
    } catch ( Exception e ) {
      new ErrorDialog( spoon.getShell(),
        BaseMessages.getString( PKG, "Spoon.Dialog.ErrorReadingSharedObjects.Title" ),
        BaseMessages.getString( PKG, "Spoon.Dialog.ErrorReadingSharedObjects.Message", spoon.delegates.tabs.makeTabName( jobMeta, true ) ), e );
    }
  }

  // If we added properties, add them to the variables too, so that they appear in the CTRL-SPACE variable completion.
  //
  spoon.setParametersAsVariablesInUI( jobMeta, jobMeta );

  if ( jd.isSharedObjectsFileChanged() || ji != null ) {
    spoon.refreshTree();
    spoon.delegates.tabs.renameTabs(); // cheap operation, might as will do it anyway
  }

  spoon.setShellText();
  return ji != null;
}
 
开发者ID:pentaho,项目名称:pentaho-kettle,代码行数:36,代码来源:JobGraph.java

示例6: open

import org.pentaho.di.ui.job.dialog.JobDialog; //导入依赖的package包/类
public JobEntryInterface open()
{
	Shell parent = getParent();
	Display display = parent.getDisplay();

       shell = new Shell(parent, SWT.DIALOG_TRIM | SWT.RESIZE | SWT.MAX | SWT.MIN);
		props.setLook(shell);
       JobDialog.setShellImage(shell, jobEntry);

	FormLayout formLayout = new FormLayout ();
	formLayout.marginWidth  = Const.FORM_MARGIN;
	formLayout.marginHeight = Const.FORM_MARGIN;

	shell.setLayout(formLayout);
	shell.setText("Do Login ON EAI");
	
	int margin = Const.MARGIN;

	wOK=new Button(shell, SWT.PUSH);
	wOK.setText(" &OK ");

	BaseStepDialog.positionBottomButtons(shell, new Button[] { wOK }, margin,null);


	lsOK       = new Listener() { public void handleEvent(Event e) { ok();     } };
	
	wOK.addListener    (SWT.Selection, lsOK    );
	
       			
	// Detect X or ALT-F4 or something that kills this window...
	shell.addShellListener(	new ShellAdapter() { public void shellClosed(ShellEvent e) { ok(); } } );
			
	
	BaseStepDialog.setSize(shell);

	shell.open();
	while (!shell.isDisposed())
	{
	    if (!display.readAndDispatch()) display.sleep();
	}
	return jobEntry;
}
 
开发者ID:xpandit,项目名称:pentaho-solution-builder,代码行数:43,代码来源:JobEntryIvyLoaderDialog.java


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