Results 1 to 2 of 2
- 03-02-2010, 10:03 PM #1Member
- Join Date
- Mar 2010
- Rep Power
My question has to do with path: WebContent/WEB_INF/classes
My understanding of these directories are the following:
WebContent/WEB-INF – the folder contains the supporting Web resources for a Web application, including the web.xml deployment descriptor file and the classes and lib directories. The web.xml file contains general information about the Web application, including Servlet mappings, security information, and the welcome page.
WebContent/WEB-INF/classes - The WebContent/WEB-INF/classes folder contains servlets, utility classes, and the Java compiler output directory. The classes in this directory are used by the application class loader to load the classes. Folders in this directory will map package and class names. The .class files are automatically placed in this directory when the Java compiler compiles the source files from the source directory. Any files placed directly in this directory will be deleted by the Java compiler when it runs.
OK - thats some decent information. That said - one area that has me confused is the classes directory. How is the directory populated? Or what is the process? You have multiple classes here – how are they created? Utility classes - how? Are they created from the java source code files? Can they be documented (via APIs)?
Consider this a newbie question coupled with a brain hiccup.
Any comments offered here would be appreciated - thanks...
- 03-03-2010, 01:28 AM #2Senior Member
- Join Date
- Dec 2009
- Belgrade, Serbia
- Rep Power
Nothing to worry about.
Your IDE does it for you.
When you create web project it has some predefined structure (there is actual specification for this).
Yours is just to write src code in "src" folder and behind scenes code is
compiled and put where project structure need it.
So just write all your source code for classes, beans, and servlets, utils in src
using packages u need and compiled code will end up in some default ouput folder like "build\classes"
Later just use Project=>Export=>Web=>WAR
create your web archive file and place it in web server to run your application.
- By arrech326 in forum New To JavaReplies: 4Last Post: 11-24-2009, 07:34 AM
- By rameshsathasivam in forum JavaServer Pages (JSP) and JSTLReplies: 0Last Post: 11-25-2008, 09:41 AM
- By escuja in forum CLDC and MIDPReplies: 0Last Post: 07-26-2008, 01:03 PM
- By Assaf A in forum EclipseReplies: 1Last Post: 04-22-2008, 03:31 PM
- By Joe2003 in forum Advanced JavaReplies: 1Last Post: 01-02-2008, 08:08 PM