title: How does Java classpath assembly work ?
body: <p>I've always taken the classpath for granted, i.e.  - its something that eclipse, maven , ant , etc handled for me.  Its obvious that the classpath is the place where java "looks" for binary classes which are executed / integrated with an application. </p>
  
  <p>However, there are some intricacies which are not clearly described. </p>
  
  <p>1) How does java "find" classes in the classpath ? </p>
  
  <p>2) How are collisions handled by javac when looking into the classpath ? </p>
  
  <p>3) What is happening "under the hood" when tools like maven/ant add/ignore elements to the classpath ?  Do these tools simply wrap the javac program ? </p>
  
  <p>4) Finally : is there an example of a "manual" complicated build for java, that doesnt use the modern generation of build tools --- just for educational purposes -- which is available ?</p>