Skip to content

Commit 68367d4

Browse files
Update README.md
1 parent de6fed5 commit 68367d4

File tree

1 file changed

+26
-5
lines changed

1 file changed

+26
-5
lines changed

README.md

Lines changed: 26 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -27,10 +27,10 @@ For detailed information, please see the [User Guide](fUML-C++_User_Guide.pdf) s
2727
### 2. Environment Variables
2828
* Add binary directories paths of *uml* and *fuml* to your system's environment variables (e.g. add them to PATH in Windows)
2929
* Depending on whether you want to build debug version, release version or both versions of the dynamic libraries:
30-
* `%fUML-C++_root%\uml\Debug` for debug version of uml
31-
* `%fUML-C++_root%\uml\Release` for release version of uml
32-
* `%fUML-C++_root%\fuml\Debug` for debug version of fuml
33-
* `%fUML-C++_root%\fuml\Release` for release version of fuml
30+
* `"<fUML-C++-rootdir>\uml\Debug"` for debug version of uml
31+
* `"<fUML-C++-rootdir>\uml\Release"` for release version of uml
32+
* `"<fUML-C++-rootdir>\fuml\Debug"` for debug version of fuml
33+
* `"<fUML-C++-rootdir>\fuml\Release"` for release version of fuml
3434

3535
## Building
3636
For detailed information, please see the [User Guide](fUML-C++_User_Guide.pdf) section *3. Build*.
@@ -40,4 +40,25 @@ For detailed information, please see the [User Guide](fUML-C++_User_Guide.pdf) s
4040
## Usage
4141
For detailed information, please see the [User Guide](fUML-C++_User_Guide.pdf) section *4. Usage*.
4242
### 1. Creating executable models using source code
43-
### 2. Generating executable models from *.uml* models
43+
* Create new C++ project (see `"<fUML-C++-rootdir>\examples\helloworld"` as a reference project)
44+
* NOTE: it is suggested to store user-defined source code projects in common directory `"<fUML-C++-rootdir>\usersrc"`
45+
* The *usersrc* directory may contain arbitrary nested subdirectories
46+
* Add include directories for uml and fuml to your project
47+
* Add uml and fuml binaries to the linker options of your projects
48+
* Create a `<model-name>Environment` class by deriving from class `fuml::environment::Environment`
49+
* Create a `<model-name>Model` class by deriving from class `uml::environment::InMemoryModel` (this class will contain all of your model elements)
50+
* Create a class containing a main method and call `<model-name>Environment::Instance()->execute("<behavior-name>");` for each behavior you want to execute in subsequent order
51+
* Build project and run executable
52+
### 2. Generating executable models from *.uml* models (*Acceleo* plugin for Eclipse has to be installed)
53+
* Create new *.uml* model with a modeling tool of your choice (*Eclipse Papyrus* is suggested)
54+
* NOTE: it is suggested to store user-defined models in common directory `"<fUML-C++-rootdir>\usermodels"`
55+
* The *usermodels* directory may contain arbitrary nested subdirectories
56+
* Import nested project *generator* within fUML-C++ root project
57+
* Navigate to file `\generator\src\fuml.generator.main\generate.mtl` in the project explorer
58+
* Right click `generate.mtl` and choose `Run as`-->`Run configurations...`
59+
* Configure and run Acceleo Application accordingly:
60+
* Choose `fuml.generator.main.Generate`
61+
* Choose your model file
62+
* Choose a target directory for the generated source code (`"<fUML-C++-rootdir>\usersrc\<model-name>"` is suggested)
63+
* Import newly generated C++ project within fUML-C++ root project and build executable(s)
64+
* Run executable from command line using `<executable-name> <behavior-name> [<behavior-name> <behavior-name> <behavior-name> <...>]`

0 commit comments

Comments
 (0)