0

Possible Duplicate:
What is the difference between Class Path and Build Path

I am using eclipse to build a dynamic web project with struts2 framework. At first, I put the struts.xml under the WEB-INF directory and build path to it, but I failed to run the web project. After I make a source package under the src diretory and put struts.xml in it, the web project can run normally.

I am confused about that put a java file in source package means put the responding compiled class in the bin directory and class_path which makes the other classes can find it, then what does build path action in eclipse do?

Community
  • 1
  • 1
jerry_sjtu
  • 5,216
  • 8
  • 29
  • 42

1 Answers1

2

A source path entry is a folder, where Eclipse will look for JAVA files, a build path entry is a place (folder/jar), where Eclipse/java will look for CLASS files.

All the files from a source path entry will get compiled (if .java) and then copied (alongside other, non java files) to the output folder specified in project configuration. Those files are relevant to javaC, the compiler.

Build Path entries are only relevant to java, the runtime.

Dario Pedol
  • 2,070
  • 14
  • 24