The examples demonstrate the usage of jaCG. You can find the source of the examples in the distribution under the directory example. To execute one of the examples call
ant example-N
where N is the number of the example you want to execute.
This example demonstrates the basics of jaCG. It shows how to setup the environment and how the generation process works. The result is a simple java bean.
This example demonstrates how to extend templates with the java extend mechanism. jaCG uses java as its template language. So you have the full java power for template programming including extending and method overloading.
This example demonstrate how to write model transformations. In a real project model transformations are a great tool for abstraction. This is one of the big advantages in a model driven architecture.
This example replaces the simple meta model of jaCG with a java 5 meta model. That means that you need java 5 to run this example.