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


Java TransGraph类代码示例

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


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

示例1: detachUnitTest

import org.pentaho.di.ui.spoon.trans.TransGraph; //导入依赖的package包/类
public void detachUnitTest() {
  Spoon spoon = ( (Spoon) SpoonFactory.getInstance() );
  try {
    TransGraph transGraph = spoon.getActiveTransGraph();
    if ( transGraph == null ) {
      return;
    }
    TransMeta transMeta = spoon.getActiveTransformation();
    if (transMeta == null ) {
      return;
    }

    transMeta.setAttribute( DataSetConst.ATTR_GROUP_DATASET, DataSetConst.ATTR_TRANS_SELECTED_UNIT_TEST_NAME, null );
    transMeta.setChanged();
    
    DataSetConst.clearStepDataSetIndicators( transMeta );
    
    spoon.refreshGraph();
  } catch ( Exception e ) {
    new ErrorDialog( spoon.getShell(), "Error", "Error detaching unit test", e );
  }
}
 
开发者ID:mattcasters,项目名称:pentaho-pdi-dataset,代码行数:23,代码来源:DataSetHelper.java

示例2: getActiveMeta

import org.pentaho.di.ui.spoon.trans.TransGraph; //导入依赖的package包/类
public EngineMetaInterface getActiveMeta()
{
	TabSet tabfolder = spoon.tabfolder;
	if (tabfolder == null)
		return null;
	TabItem tabItem = tabfolder.getSelected();
	if (tabItem == null)
		return null;

	// What transformation is in the active tab?
	// TransLog, TransGraph & TransHist contain the same transformation
	//
	TabMapEntry mapEntry = getTab(tabfolder.getSelected());
	EngineMetaInterface meta = null;
	if (mapEntry != null)
	{
		if (mapEntry.getObject() instanceof TransGraph)
			meta = (mapEntry.getObject()).getMeta();
		if (mapEntry.getObject() instanceof JobGraph)
			meta = (mapEntry.getObject()).getMeta();
	}

	return meta;
}
 
开发者ID:icholy,项目名称:geokettle-2.0,代码行数:25,代码来源:SpoonTabsDelegate.java

示例3: refreshGraph

import org.pentaho.di.ui.spoon.trans.TransGraph; //导入依赖的package包/类
public void refreshGraph() {
	if (shell.isDisposed())
		return;

	TabItem tabItem = tabfolder.getSelected();
	if (tabItem == null)
		return;

	TabMapEntry tabMapEntry = delegates.tabs.getTab(tabItem);
	if (tabMapEntry.getObject() instanceof TransGraph) {
		TransGraph transGraph = (TransGraph) tabMapEntry.getObject();
		transGraph.redraw();
	}
	if (tabMapEntry.getObject() instanceof JobGraph) {
		JobGraph jobGraph = (JobGraph) tabMapEntry.getObject();
		jobGraph.redraw();
	}

	setShellText();
}
 
开发者ID:icholy,项目名称:geokettle-2.0,代码行数:21,代码来源:Spoon.java

示例4: printTransFile

import org.pentaho.di.ui.spoon.trans.TransGraph; //导入依赖的package包/类
private void printTransFile(TransMeta transMeta) {
	TransGraph transGraph = getActiveTransGraph();
	if (transGraph == null)
		return;

	PrintSpool ps = new PrintSpool();
	Printer printer = ps.getPrinter(shell);

	// Create an image of the screen
	Point max = transMeta.getMaximum();

	Image img = transGraph.getTransformationImage(printer, max.x, max.y, false, 1.0f);

	ps.printImage(shell, img);

	img.dispose();
	ps.dispose();
}
 
开发者ID:icholy,项目名称:geokettle-2.0,代码行数:19,代码来源:Spoon.java

示例5: getActiveMeta

import org.pentaho.di.ui.spoon.trans.TransGraph; //导入依赖的package包/类
public EngineMetaInterface getActiveMeta() {
	if (tabfolder == null)
		return null;
	TabItem tabItem = tabfolder.getSelected();
	if (tabItem == null)
		return null;

	// What transformation is in the active tab?
	// TransLog, TransGraph & TransHist contain the same transformation
	//
	TabMapEntry mapEntry = delegates.tabs.getTab(tabfolder.getSelected());
	EngineMetaInterface meta = null;
	if (mapEntry != null) {
		if (mapEntry.getObject() instanceof TransGraph)
			meta = (mapEntry.getObject()).getMeta();
		if (mapEntry.getObject() instanceof JobGraph)
			meta = (mapEntry.getObject()).getMeta();
	}

	return meta;
}
 
开发者ID:icholy,项目名称:geokettle-2.0,代码行数:22,代码来源:Spoon.java

示例6: undoAction

import org.pentaho.di.ui.spoon.trans.TransGraph; //导入依赖的package包/类
public void undoAction(UndoInterface undoInterface) {
	if (undoInterface == null)
		return;

	TransAction ta = undoInterface.previousUndo();
	if (ta == null)
		return;

	setUndoMenu(undoInterface); // something changed: change the menu

	if (undoInterface instanceof TransMeta)
		delegates.trans.undoTransformationAction((TransMeta) undoInterface, ta);
	if (undoInterface instanceof JobMeta)
		delegates.jobs.undoJobAction((JobMeta) undoInterface, ta);

	// Put what we undo in focus
	if (undoInterface instanceof TransMeta) {
		TransGraph transGraph = delegates.trans.findTransGraphOfTransformation((TransMeta) undoInterface);
		transGraph.forceFocus();
	}
	if (undoInterface instanceof JobMeta) {
		JobGraph jobGraph = delegates.jobs.findJobGraphOfJob((JobMeta) undoInterface);
		jobGraph.forceFocus();
	}
}
 
开发者ID:icholy,项目名称:geokettle-2.0,代码行数:26,代码来源:Spoon.java

示例7: redoAction

import org.pentaho.di.ui.spoon.trans.TransGraph; //导入依赖的package包/类
public void redoAction(UndoInterface undoInterface) {
	if (undoInterface == null)
		return;

	TransAction ta = undoInterface.nextUndo();
	if (ta == null)
		return;

	setUndoMenu(undoInterface); // something changed: change the menu

	if (undoInterface instanceof TransMeta)
		delegates.trans.redoTransformationAction((TransMeta) undoInterface, ta);
	if (undoInterface instanceof JobMeta)
		delegates.jobs.redoJobAction((JobMeta) undoInterface, ta);

	// Put what we redo in focus
	if (undoInterface instanceof TransMeta) {
		TransGraph transGraph = delegates.trans.findTransGraphOfTransformation((TransMeta) undoInterface);
		transGraph.forceFocus();
	}
	if (undoInterface instanceof JobMeta) {
		JobGraph jobGraph = delegates.jobs.findJobGraphOfJob((JobMeta) undoInterface);
		jobGraph.forceFocus();
	}
}
 
开发者ID:icholy,项目名称:geokettle-2.0,代码行数:26,代码来源:Spoon.java

示例8: showLastTransCheck

import org.pentaho.di.ui.spoon.trans.TransGraph; //导入依赖的package包/类
/**
 * Show the remarks of the last transformation check that was run.
 * 
 * @see #checkTrans()
 */
public void showLastTransCheck() {
	TransMeta transMeta = getActiveTransformation();
	if (transMeta == null)
		return;
	TransGraph transGraph = delegates.trans.findTransGraphOfTransformation(transMeta);
	if (transGraph == null)
		return;

	CheckResultDialog crd = new CheckResultDialog(transMeta, shell, SWT.NONE, transGraph.getRemarks());
	String stepname = crd.open();
	if (stepname != null) {
		// Go to the indicated step!
		StepMeta stepMeta = transMeta.findStep(stepname);
		if (stepMeta != null) {
			delegates.steps.editStep(transMeta, stepMeta);
		}
	}
}
 
开发者ID:icholy,项目名称:geokettle-2.0,代码行数:24,代码来源:Spoon.java

示例9: refreshGraph

import org.pentaho.di.ui.spoon.trans.TransGraph; //导入依赖的package包/类
public void refreshGraph() {
  if (shell.isDisposed())
    return;

  TabItem tabItem = tabfolder.getSelected();
  if (tabItem == null)
    return;

  TabMapEntry tabMapEntry = delegates.tabs.getTab(tabItem);
  if (tabMapEntry!=null) {
    if (tabMapEntry.getObject() instanceof TransGraph) {
      TransGraph transGraph = (TransGraph) tabMapEntry.getObject();
      transGraph.redraw();
    }
    if (tabMapEntry.getObject() instanceof JobGraph) {
      JobGraph jobGraph = (JobGraph) tabMapEntry.getObject();
      jobGraph.redraw();
    }
  }

  setShellText();
}
 
开发者ID:yintaoxue,项目名称:read-open-source-code,代码行数:23,代码来源:Spoon.java

示例10: printTransFile

import org.pentaho.di.ui.spoon.trans.TransGraph; //导入依赖的package包/类
private void printTransFile(TransMeta transMeta) {
  TransGraph transGraph = getActiveTransGraph();
  if (transGraph == null)
    return;

  PrintSpool ps = new PrintSpool();
  Printer printer = ps.getPrinter(shell);

  // Create an image of the screen
  Point max = transMeta.getMaximum();

  Image img = transGraph.getTransformationImage(printer, max.x, max.y, 1.0f);

  ps.printImage(shell, img);

  img.dispose();
  ps.dispose();
}
 
开发者ID:yintaoxue,项目名称:read-open-source-code,代码行数:19,代码来源:Spoon.java

示例11: getActiveTransGraph

import org.pentaho.di.ui.spoon.trans.TransGraph; //导入依赖的package包/类
public TransGraph getActiveTransGraph() {
  if(tabfolder != null) {
    if (tabfolder.getSelected() == null)
      return null;      
  } else {
    return null;
  }
  if(delegates != null && delegates.tabs != null) {
    TabMapEntry mapEntry = delegates.tabs.getTab(tabfolder.getSelected());
    if (mapEntry != null) {
      if (mapEntry.getObject() instanceof TransGraph) {
        return (TransGraph) mapEntry.getObject();
      }
    }
  }
  return null;
}
 
开发者ID:yintaoxue,项目名称:read-open-source-code,代码行数:18,代码来源:Spoon.java

示例12: undoAction

import org.pentaho.di.ui.spoon.trans.TransGraph; //导入依赖的package包/类
public void undoAction(UndoInterface undoInterface) {
  if (undoInterface == null)
    return;

  TransAction ta = undoInterface.previousUndo();
  if (ta == null)
    return;

  setUndoMenu(undoInterface); // something changed: change the menu

  if (undoInterface instanceof TransMeta)
    delegates.trans.undoTransformationAction((TransMeta) undoInterface, ta);
  if (undoInterface instanceof JobMeta)
    delegates.jobs.undoJobAction((JobMeta) undoInterface, ta);

  // Put what we undo in focus
  if (undoInterface instanceof TransMeta) {
    TransGraph transGraph = delegates.trans.findTransGraphOfTransformation((TransMeta) undoInterface);
    transGraph.forceFocus();
  }
  if (undoInterface instanceof JobMeta) {
    JobGraph jobGraph = delegates.jobs.findJobGraphOfJob((JobMeta) undoInterface);
    jobGraph.forceFocus();
  }
}
 
开发者ID:yintaoxue,项目名称:read-open-source-code,代码行数:26,代码来源:Spoon.java

示例13: redoAction

import org.pentaho.di.ui.spoon.trans.TransGraph; //导入依赖的package包/类
public void redoAction(UndoInterface undoInterface) {
  if (undoInterface == null)
    return;

  TransAction ta = undoInterface.nextUndo();
  if (ta == null)
    return;

  setUndoMenu(undoInterface); // something changed: change the menu

  if (undoInterface instanceof TransMeta)
    delegates.trans.redoTransformationAction((TransMeta) undoInterface, ta);
  if (undoInterface instanceof JobMeta)
    delegates.jobs.redoJobAction((JobMeta) undoInterface, ta);

  // Put what we redo in focus
  if (undoInterface instanceof TransMeta) {
    TransGraph transGraph = delegates.trans.findTransGraphOfTransformation((TransMeta) undoInterface);
    transGraph.forceFocus();
  }
  if (undoInterface instanceof JobMeta) {
    JobGraph jobGraph = delegates.jobs.findJobGraphOfJob((JobMeta) undoInterface);
    jobGraph.forceFocus();
  }
}
 
开发者ID:yintaoxue,项目名称:read-open-source-code,代码行数:26,代码来源:Spoon.java

示例14: showLastTransCheck

import org.pentaho.di.ui.spoon.trans.TransGraph; //导入依赖的package包/类
/**
 * Show the remarks of the last transformation check that was run.
 * 
 * @see #checkTrans()
 */
public void showLastTransCheck() {
  TransMeta transMeta = getActiveTransformation();
  if (transMeta == null)
    return;
  TransGraph transGraph = delegates.trans.findTransGraphOfTransformation(transMeta);
  if (transGraph == null)
    return;

  CheckResultDialog crd = new CheckResultDialog(transMeta, shell, SWT.NONE, transGraph.getRemarks());
  String stepname = crd.open();
  if (stepname != null) {
    // Go to the indicated step!
    StepMeta stepMeta = transMeta.findStep(stepname);
    if (stepMeta != null) {
      delegates.steps.editStep(transMeta, stepMeta);
    }
  }
}
 
开发者ID:yintaoxue,项目名称:read-open-source-code,代码行数:24,代码来源:Spoon.java

示例15: getActiveMeta

import org.pentaho.di.ui.spoon.trans.TransGraph; //导入依赖的package包/类
public EngineMetaInterface getActiveMeta() {

    if (tabfolder == null)
      return null;
    
    TabItem tabItem = tabfolder.getSelected();
    if (tabItem == null)
      return null;

    // What transformation is in the active tab?
    // TransLog, TransGraph & TransHist contain the same transformation
    //
    TabMapEntry mapEntry = ((Spoon) SpoonFactory.getInstance()).delegates.tabs.getTab(tabfolder.getSelected());
    EngineMetaInterface meta = null;
    if (mapEntry != null) {
      if (mapEntry.getObject() instanceof TransGraph)
        meta = (mapEntry.getObject()).getMeta();
      if (mapEntry.getObject() instanceof JobGraph)
        meta = (mapEntry.getObject()).getMeta();
    }

    return meta;
    
  }
 
开发者ID:yintaoxue,项目名称:read-open-source-code,代码行数:25,代码来源:MainSpoonPerspective.java


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