Hi Simone, I'm not sure to understand what are you trying to do... can you elaborate on that?
Are you looking a way to programatically create your processes? if is that what you are looking for I recommend you to look at the fluent API.
Take a look at the test called: ProcessFactoryTest inside jbpm-flow project:
https://github.com/krisv/jbpm/blob/master/jbpm-flow/src/test/java/org/jbpm/process/ProcessFactoryTest.java
Greetings.