-
packages
Hello,
I have a file at:
\Data Persistence\data_persistence
that needs to access a package at:
\Data Persistence\UserAccounts
When starting my file with:
Code:
import UserAccounts.*;
I get:
Code:
index.java:37: package UserAccounts does not exist
import UserAccounts.*;
How can I reach this package that is in a folder beside data_persistence?
Thanks,
-
Set your CLASSPATH to include the \Data Persistence directory, and make sure the classes in the UserAccounts directory have at the top:
Code:
package UserAccounts;
FYI, convention has packages as all lower case except when acronyms are in play, although this is not required by the language.