user2602584
user2602584

Reputation: 797

Generate dynamic web app structure J2EE

Is there any Method or API that will help me to generate the structure of dynamic web app in eclipse? I want to generate the whole structure: /src; /WebContent/WEB-IN,.. and the web.xml. I am trying to develop an app that takes the Model Class and generates all the basic web app for those Model Class.

Upvotes: 3

Views: 182

Answers (2)

lgu
lgu

Reputation: 2460

You shoul try this development accelerator https://sites.google.com/site/telosystutorial/ (different examples with Spring MVC, Spring Data, etc )

Upvotes: 1

Chris Gerken
Chris Gerken

Reputation: 16390

That's what M2T-JET was designed for. It's a template-based generator (think JSP in Eclipse). Use these tags in the main.jet template:

  • ws:project creates an eclipse project with the specified name
  • ws:folder creates an eclipse folder with the specified path
  • ws:file creates a file with the given path using content derived from applying the input model to a specified .jet template

The input model is usually XML, but there are loaders in JET that can use other sources as models: Eclipse itself, EMF models and - of more interest to you - java source files. This java loader takes java source, parses it into an AST model and then passes that model on to the main.jet template.

Upvotes: 3

Related Questions