[kepler-dev] Adding actors to the workflow programmatically

Edward A. Lee eal at eecs.berkeley.edu
Thu Jan 10 09:02:21 PST 2008


When you drag an actor in, the outline of what happens is:

  actor = the selected actor in the library;
  String xml = actor.exportMoML();
  model = the composite actor being edited.
  MoMLChangeRequest request = new MoMLChangeRequest(..., xml, ...);
  model.requestChange(request);

I.e., a MoML description of the actor to drop in is obtained,
and a change request is used to insert that MoML into the model.

Edward


At 04:05 AM 1/10/2008, R.P.Mciver at cs.cardiff.ac.uk wrote:
>Hi,
>
>I've been playing about with trying to add Actors to a workflow in a  
>manner different to dragging them from the tree of those available,  
>however I've not been having much luck!
>
>I was wondering if anyone could tell me what code is actually executed  
>when the user drags an entity from the tree onto the workflow? And is  
>there a simple "addEntity" command that could be used to add an actor  
>to an existing workflow?
>
>Thanks in advance to anyone who can help!
>
>Russell
>
>----------------------------------------------------------------
>This message was sent using IMP, the Internet Messaging Program.
>
>
>_______________________________________________
>Kepler-dev mailing list
>Kepler-dev at ecoinformatics.org
>http://mercury.nceas.ucsb.edu/ecoinformatics/mailman/listinfo/kepler-dev

------------ 
Edward A. Lee
Chair of EECS and Robert S. Pepper Distinguished Professor
231 Cory Hall, UC Berkeley, Berkeley, CA 94720-1770
phone: 510-642-0253, fax: 510-642-2845
eal at eecs.Berkeley.EDU, http://www.eecs.berkeley.edu/Faculty/Homepages/lee.html  



More information about the Kepler-dev mailing list