Win a copy of Design for the Mind this week in the Design forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Different Web app structural views

 
shivang sarawagi
Ranch Hand
Posts: 157
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Generally after developing a dynamic web project in eclipse we get the application structure as "src" "webcontent".
But there is another structure of web applications. Can anyone provide me an insight as to how that structure
of a web application is achieved.
Images in the attachments.

Web_layoutOne.png
Conventional dynamic web project in eclipse
[Thumbnail for Web_layoutOne.png]
Web_layoutTwo.png
Web app structure type2
[Thumbnail for Web_layoutTwo.png]
Web_layoutThree.png
Web app structure after clicking on src
[Thumbnail for Web_layoutThree.png]
 
Saif Asif
Ranch Hand
Posts: 440
Eclipse IDE Hibernate Linux
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I strongly advise you to follow the Standard Directory Structure (-link) as proposed by Apache in their maven project. Although it was initially introduced for the maven projects , but I have seen a lot of people follow it because of its standardized and easy to follow directory hierarchy.
 
shivang sarawagi
Ranch Hand
Posts: 157
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks for the reply. So if I build by project with maven I will get the same directory structure?
 
Saif Asif
Ranch Hand
Posts: 440
Eclipse IDE Hibernate Linux
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
shivang sarawagi wrote:Thanks for the reply. So if I build by project with maven I will get the same directory structure?


You have two choices, either make changes in your current directory structure to the standard directory structure , or (if you want to use maven as your build tool ) make use of the Maven archetypes. These archetypes are basically skeleton project structures that can be downloaded are ready to use . You will see that the whole of the directory structure is already set up in these archetypes.
 
Bear Bibeault
Author and ninkuma
Marshal
Pie
Posts: 64712
86
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Saif Asif wrote:You have two choices,

There are way more than two choices. I don't use either of eclipse or maven, so my organization is very different from any of those.

What it comes down to is that, outside of WEB-INF, the organization is up to the developer and the tools being used. Some IDEs require a specific structure, as do some frameworks.

The organization within WEB-INF, of course, is dictated by the servlet spec.
 
Saif Asif
Ranch Hand
Posts: 440
Eclipse IDE Hibernate Linux
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Bear wrote: I don't use either of eclipse or maven, so my organization is very different from any of those.


What organization do you use Bear ?
 
Bear Bibeault
Author and ninkuma
Marshal
Pie
Posts: 64712
86
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
It really depends upon the purpose of the application and what tools I am using. For example, for projects where I use the Play! framework, the structure is dictated by the framework.
 
Saif Asif
Ranch Hand
Posts: 440
Eclipse IDE Hibernate Linux
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I see . And its far better to use the structure defined by the framework rather than to configure and use an entirely different structure.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic