Definiti
Last updated
Last updated
Does your language enable you to describe your domain? Does it only describe you domain or do technical stuffs are in your way?
The objective of Definiti is to provide a declarative language and tools to help you describe your domain and throw out technical code at the edge of your application.
Define all your domain logic in Definiti language, then generate sources code in your technical languages such as Scala or Typescript.
It is also possible to generate other things than sources files, as glossary, plantUML diagrams and more.
The following diagram represents a simple workflow with Definiti:
Definiti is not intended to work as a standalone language. Please check which languages are supported before using it.
We use docker to download and execute the Definiti compiler. Please refers to the documentation to install it on your environment.
To start using Definiti, execute the following installation command:
You will be ask for the version, the languages and the plugins to use. For instance, we will take following configuration:
version: default
languages: scala
plugins: none
Once done, write your first Definiti file in src/main/definiti/blog.def
(we will come back to the syntax later):
Then compile it:
You will see a new directory: target/scalamodel
with the most interesting file my/blog/blog.scala
:
You can now use it in your own project:
Please check the left panel to go through the documentation.