Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » M2T (model-to-text transformation) » How can i run Workflow from java code
How can i run Workflow from java code [message #1009476] Fri, 15 February 2013 07:59 Go to next message
serhat gezgin is currently offline serhat gezgin
Messages: 239
Registered: January 2013
Location: Izmir
Senior Member
I need to run workflow from java and i found ;

WorkflowRunner runner = new WorkflowRunner();
		HashMap<String, Object> externalSlotContents = new HashMap<String, Object>();
		HashMap<String, String> theParams = new HashMap<String, String>();
		theParams.put("modelFile", "model/Case2.xml");
		runner.run("workflow/Workflow.mwe", new NullProgressMonitor(),
				theParams, externalSlotContents);


but java says runner.run method is deprecated so How do I run workflow from other ways ?
Re: How can i run Workflow from java code [message #1009676 is a reply to message #1009476] Fri, 15 February 2013 14:04 Go to previous messageGo to next message
Christian Dietrich is currently offline Christian Dietrich
Messages: 6307
Registered: July 2009
Senior Member
Hi,

what about calling the main method respectively toRun instead?
Re: How can i run Workflow from java code [message #1010055 is a reply to message #1009676] Sat, 16 February 2013 11:53 Go to previous messageGo to next message
serhat gezgin is currently offline serhat gezgin
Messages: 239
Registered: January 2013
Location: Izmir
Senior Member
How can i use main method ? I can't see any sample
Re: How can i run Workflow from java code [message #1010060 is a reply to message #1010055] Sat, 16 February 2013 12:05 Go to previous messageGo to next message
serhat gezgin is currently offline serhat gezgin
Messages: 239
Registered: January 2013
Location: Izmir
Senior Member
And how can i change Workflow file properties with main method or i must use something else ?

for example <uri value='${modelFile}' /> ;
<component class="org.eclipse.xtend.typesystem.xsd.XMLReader">
    <modelSlot value="model" />
    <uri value='${modelFile}' />
    <metaModel id="mm"
      class="org.eclipse.xtend.typesystem.xsd.XSDMetaModel">
      <schemaFile value="metamodel/ir.xsd" />
    </metaModel>
  </component>

[Updated on: Sun, 17 February 2013 11:08]

Report message to a moderator

Re: How can i run Workflow from java code [message #1010083 is a reply to message #1010060] Sat, 16 February 2013 13:40 Go to previous messageGo to next message
Christian Dietrich is currently offline Christian Dietrich
Messages: 6307
Registered: July 2009
Senior Member
-p modelFile=....???
Re: How can i run Workflow from java code [message #1010764 is a reply to message #1010083] Mon, 18 February 2013 07:49 Go to previous messageGo to next message
serhat gezgin is currently offline serhat gezgin
Messages: 239
Registered: January 2013
Location: Izmir
Senior Member
dont understand Sad
Re: How can i run Workflow from java code [message #1010777 is a reply to message #1010764] Mon, 18 February 2013 08:13 Go to previous message
Christian Dietrich is currently offline Christian Dietrich
Messages: 6307
Registered: July 2009
Senior Member
I fear you have actually to look into the code Sad
Previous Topic:[Acceleo] template/generation error listening
Next Topic:Acceleo protected regions
Goto Forum:
  


Current Time: Sun Sep 21 04:18:37 GMT 2014

Powered by FUDForum. Page generated in 0.10492 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software