I am on page 82 of Head First and am compiling BeerExpert.
i created beerexpert.java as following:
------------------------------------------------------------------------------------------------------------
----------------------------------------------------------------------------------------------------------------
i compiled this above
java file successfully.
then i created beerselect.java as following:
-----------------------------------------------------------------------------------------------------------------
--------------------------------------------------------------------------------------------------------------------
then i used followig commands to compile it:
E:\MyProjects\beerV1\src\com\example\web> //reached dir where beerselect.java exists.
E:\MyProjects\beerV1\src\com\example\web>javac beerselect.java
beerselect.java:4: package com.example.model does not exist
import com.example.model.*;
^
beerselect.java:20: cannot find symbol
symbol : class beerexpert
location: class com.example.web.beerselect
beerexpert b=new beerexpert();
^
beerselect.java:20: cannot find symbol
symbol : class beerexpert
location: class com.example.web.beerselect
beerexpert b=new beerexpert();
^
3 errors
------------------------------------------------------------------------------------------------------------------------
I have already set environment variables as following:
CLASSPATH C:\Program Files\Apache Software Foundation\Tomcat 6.0\lib\servlet-api.jar
JAVA_HOME C:\Program Files\Java\jdk1.6.0
PATH C:\Program Files\Java\jdk1.6.0\bin
development environment dir structure is same as depicted in the book.
one more thing i am not willing to write long classpath in my compiling command. So, is there any way?
what should i do to remove these errors?
please help me out.
thanks in advance