将GMF与Xpand Oaw集成
-
25-10-2019 - |
题
试图将GMF与XPAND集成。
我创建了一个菜单,并使用GMF清单文件中的扩展名命令。并正在尝试调用Xpand Generator。
命令的代码如下所示
public class customCommand extends AbstractHandler implements IHandler {
@Override
public Object execute(ExecutionEvent event) throws ExecutionException {
// TODO Auto-generated method stub
Shell s=HandlerUtil.getActiveShell(event);
MessageBox mb=new MessageBox(s,SWT.None);
WorkflowRunner runner = new WorkflowRunner();
Bundle bundle=Platform.getBundle("MistScriptGenerator");
URL wfUrl = bundle.getEntry("src/workflow/generator.oaw");
String wfFile = "";
try {
wfFile = FileLocator.toFileURL(wfUrl).getFile();
mb.setMessage(wfFile);
mb.open();
Map<String, String> properties = new HashMap<String, String>();
//properties.put("model", $diagramFile$.getLocation().toOSString());
properties=null;
boolean isSuccess = runner.run(wfFile,new org.openarchitectureware.workflow.monitor.NullProgressMonito r(), properties, null);
}
catch (Exception e)
{
}
return null;
}
}
我已经能够成功获得工作流程的路径。现在,在调用工作流程时,我将不得不将GMF图文件输入工作流。但是如何为文件提供路径呢?
我通过打开另一个工作台来执行GMF Digram:但是,现在,如何获得GMF图文件的路径?
我在工作流程中注册了epackage。
您能指导我项目截止日期很快吗?
不隶属于 StackOverflow