cannot find symbol?

L

lbrtchx

Hi,

I am trying to create an abstract class with their particular
implementations for the different decompress formats java supports (I
know it works. I have done it before), but I am getting some
uncomprehensible "cannot find symbol" error, even though I did compile
the implementation classes first and I am making them accessible
through the classpath

What does this error mean in this case?

How can I fix it?

lbrtchx

sh-3.1# javac -cp ./activation.jar:./tar.jar:. ReadInFls00Test.java
ReadInFls00Test.java:9: cannot find symbol
symbol : class Unzip00
location: class ReadInFls00Test
DKPrx[0] = new Unzip00(aZ[0]);
^
ReadInFls00Test.java:10: cannot find symbol
symbol : class GUnzip00
location: class ReadInFls00Test
DKPrx[1] = new GUnzip00(aZ[1]);
^
ReadInFls00Test.java:11: cannot find symbol
symbol : class TARGUnzip00
location: class ReadInFls00Test
DKPrx[2] = new TARGUnzip00(aZ[2]);
^
3 errors

sh-3.1# ls -l *UnZip00.class
-rw-r--r-- 1 root root 1814 Mar 20 06:05 GUnZip00.class
-rw-r--r-- 1 root root 2343 Mar 20 06:00 TARGUnZip00.class
-rw-r--r-- 1 root root 2577 Mar 20 06:00 UnZip00.class

sh-3.1# ls -l *.java
-rw-r--r-- 1 root root 232 Mar 20 06:09 AbsDkmprss00.java
-rw-r--r-- 1 root root 1579 Mar 20 06:09 GUnZip00.java
-rw-r--r-- 1 root root 522 Mar 20 06:07 ReadInFls00Test.java
-rw-r--r-- 1 root root 2333 Mar 20 06:09 TARGUnZip00.java
-rw-r--r-- 1 root root 2085 Mar 20 06:09 UnZip00.java
 
L

lbrtchx

What does this error mean in this case?
Java is case sensitive, from a-Z.
Thanks!

I must have had my head up my ass to not see this. It amazes me how
these stupid on your face bugs/erros can still bite you lbrtchx
 
L

Lew

sh-3.1# ls -l *UnZip00.class
-rw-r--r-- 1 root root 1814 Mar 20 06:05 GUnZip00.class
-rw-r--r-- 1 root root 2343 Mar 20 06:00 TARGUnZip00.class
-rw-r--r-- 1 root root 2577 Mar 20 06:00 UnZip00.class

sh-3.1# ls -l *.java
-rw-r--r-- 1 root root 232 Mar 20 06:09 AbsDkmprss00.java
-rw-r--r-- 1 root root 1579 Mar 20 06:09 GUnZip00.java
-rw-r--r-- 1 root root 522 Mar 20 06:07 ReadInFls00Test.java
-rw-r--r-- 1 root root 2333 Mar 20 06:09 TARGUnZip00.java
-rw-r--r-- 1 root root 2085 Mar 20 06:09 UnZip00.java

Your listings imply that you have your classes in the default package, that
you have .class and .java files in the same directory, and that you do your
work as root. That's three mistakes, if you actually did those things.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,769
Messages
2,569,580
Members
45,054
Latest member
TrimKetoBoost

Latest Threads

Top