-
Notifications
You must be signed in to change notification settings - Fork 116
Creating and using a custom generator
Kristian Karl edited this page Mar 4, 2021
·
5 revisions
The example project shows code where a custom generator is created. To use the new generator, it has been added to an example model SimpleModel.json, where the generator is referenced:
"generator": "pluginGenerator(edge_coverage(100))",
The custom generator needs to extend the GraphWalker class PathGeneratorBase<StopCondition>
See PluginGenerator.java.
To use the custom generator with GraphWlalker CLI or Studio, the new class needs to be added to the classpath:
mvn package
wget https://github.com/GraphWalker/graphwalker-project/releases/download/4.3.1/graphwalker-cli-4.3.1.jar
java -cp ./graphwalker-cli-4.3.1.jar:./target/java-plugin-generator-4.3.1-SNAPSHOT.jar org.graphwalker.cli.CLI offline -g src/main/resources/com/company/SimpleModel.json