User Tools

Site Tools


v070:userguide

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
v070:userguide [2018/10/08 16:24]
djnemeth [Modeling language]
v070:userguide [2018/10/08 22:31] (current)
djnemeth [Generating diagrams]
Line 47: Line 47:
   * ''​XtxtUML''​ for custom modelling syntax.   * ''​XtxtUML''​ for custom modelling syntax.
   * ''​JtxtUML''​ for Java syntax.   * ''​JtxtUML''​ for Java syntax.
-Both XtxtUML and JtxtUML models can be connected with Java code, can be run and debugged, and used as a source for Papyrus UML model generation.+Both XtxtUML and JtxtUML models can be connected with Java code, can be run and debugged, and used as a source for UML2 model generation.
  
 A txtUML model is a package with A txtUML model is a package with
-  * either a ''​package-info.java''​ file (in case of JtxtUML), where the package has an annotation of the form ''​@Model("​ModelName"​)''​((Fully qualified name: ''​hu.elte.txtuml.api.model.Model''​)) ​annotation,+  * either a ''​package-info.java''​ file (in case of JtxtUML), where the package has an annotation of the form ''​@Model("​ModelName"​)''​((Fully qualified name: ''​hu.elte.txtuml.api.model.Model''​)),​
   * or a ''​package-info.xtxtuml''​ file (in case of XtxtUML), which has a model declaration of the form ''​model-package example.x.model as "​ModelName";''​.   * or a ''​package-info.xtxtuml''​ file (in case of XtxtUML), which has a model declaration of the form ''​model-package example.x.model as "​ModelName";''​.
 All files in this package (and its subpackages) are part of the model. The wizard described above creates one of these files depending on the XtxtUML/​JtxtUML selection. All files in this package (and its subpackages) are part of the model. The wizard described above creates one of these files depending on the XtxtUML/​JtxtUML selection.
Line 109: Line 109:
   * a switch for toggling diagnostics mode   * a switch for toggling diagnostics mode
   * input for the port where diagnostics information is provided   * input for the port where diagnostics information is provided
-  * see [[v070:​userguide#​Animation in JavaScript]] for details+  * see section ​[[v070:​userguide#​Animation in JavaScript]] for details
 **Diagram list**: **Diagram list**:
   * a list of all class and state machine diagrams available   * a list of all class and state machine diagrams available
Line 147: Line 147:
 === Executing models === === Executing models ===
  
-txtUML models can be run as Java applications. The simplest way to run a txtUML model is to implement the [[http://​txtuml.inf.elte.hu/​releases/​txtuml-v070/​api/​java/​hu/​elte/​txtuml/​api/​model/​execution/​Execution.html|Execution]] interface, whose sole abstract method can be used as the ''​initialization()''​ of the model execution. That is, it should contain the model code which creates, links and starts the model class instances ​which should exist at the beginning of the execution.+txtUML models can be run as Java applications. The simplest way to run a txtUML model is to implement the [[http://​txtuml.inf.elte.hu/​releases/​txtuml-v070/​api/​java/​hu/​elte/​txtuml/​api/​model/​execution/​Execution.html|Execution]] interface, whose sole abstract method can be used as the ''​initialization()''​ of the model execution. That is, it should contain the model code which creates, links and starts the model class instances ​that should exist at the beginning of the execution.
  
 After the ''​initialization()''​ method is implemented,​ there are three possible ways to run the execution: After the ''​initialization()''​ method is implemented,​ there are three possible ways to run the execution:
Line 490: Line 490:
  
 <code cpp> <code cpp>
-Action::​link(AB.a, ​objA, AB.b, objB);+Action::​link(AB.a, ​instanceOfA, AB.b, instanceOfB);
 </​code>​ </​code>​
  
 <code cpp> <code cpp>
-MultipliedElement<​B,​ 0, -1> ​objBs a.assoc(AB.b);​+MultipliedElement<​B,​ 0, -1> ​bs instanceOfA.assoc(AB.b);​
   // MultipliedElement<​T,​ L, U> means:   // MultipliedElement<​T,​ L, U> means:
   //   a collection of Ts with multiplicity L..U   //   a collection of Ts with multiplicity L..U
Line 502: Line 502:
  
 <code cpp> <code cpp>
-// include '​runtime/​PortUtils.hpp'​ for direct use +delegateConnect(instanceOfA.PortAP, Conn.bpeinstanceOfB.PortBP); 
-delegateConnect(objA.PortAP, Conn.bpobjB.PortBP); +assemblyConnect(Conn.apeinstanceOfA.PortAP, Conn.bpeinstanceOfB.PortBP); 
-assemblyConnect(Conn.apobjA.PortAP, Conn.bpobjB.PortBP);+  // include '​runtime/​PortUtils.hpp'​ for direct use
 </​code>​ </​code>​
v070/userguide.1539008643.txt.gz · Last modified: 2018/10/08 16:24 by djnemeth