Skip to content
UrsZeidler edited this page Jan 6, 2016 · 37 revisions

Welcome to the uml2solidity wiki!

install

As the software is a plugin you will need the basic software witch is the eclipse platform. It comes in a great number of flavors, as c++ dev enviorment or as java. When you just interested in the modeling you could use the Papyrus Downloads

After getting the eclipse platform you need to install the solidity plugins from the updatesite.

If you want you could also install the mix solidity dev. enviorment to compile and test your contracts.

use

Create a model and apply the profile. Model your contracts and generate the code. Use the protected source parts to add the implementation. The profile is explained here. You could change some preferences.

create a model

in fast: Select new model, select and apply the solidity profile and also add the solidity types.

step by step:

create a papyrus project;

name the project:

select the uml model as diagram language:

name the model and create a class diagramm:

apply the solidity profile to the model:

finish the wizard:

import the solidity types by select the model in the modelexplorer:

generate code

After modeling your contracts, applying the stereotypes, you can generate the solidity code. The code will be generated in a sub directory called mix. When using mix you could open this directory as mix project and the generated files are loaded into mix. Now you could start to flesh out the contracts by adding the behavior code. Place your code in the protected parts. So it will stay even if you generate the code again.

The generate solidity code action is available in the toolbar:

If you already have the mix program opened the files will be reloaded.

Clone this wiki locally