How to access method from a default package??

I am working on web app using eclipse and itmill toolkit, now i have several packages and my main application class is located in default package.

Now i am in UserInterface package and i want to call a method from my main app class that is in default package. But the problem is…it is not visible.

Any help of how to access the method from default package.

Am stuck i need help.

I dont like the idea of moving my classes to the default package. That should be the last thing to do.

vbnet

Why do you have any classes in the default package? How about moving all classes from default to proper packages so that you can refer those their full packagenames?

(maybe I just did not understand the question)

Yes, don’t do that - what you probably want to do is move the classes from the default package to a ‘real’ package.

The default package is fine for really small ‘quick-and-dirty-test’ -type apps with one class (or very very few) , anything else should have package names. In fact, I’d even encourage to use package names for the quick-and-dirty stuff - who knows where it’ll end up :wink:

//Marc

the thing is…this tomcat project am working on…if i move the main app class to other package …the application wont start at all.

it hat to be at the top root which is the default package…that is why i cant move the main class to the proper package

Any package should work. What does it say in your web.xml? The application class needs the full package path there, for example:

<param-name>application</param-name>
<param-value>com.example.whatever.TheApplicationClass</param-value>

Thanks for the solution…it worked…I was not changing the param value in web.xml.

that was real cool.

thanks

vbnet