Netbeans: exclude classes from search

When programming in Netbeans, and there are some import suggestions for an unknown class, I often click on the wrong one. Especially when programming with JME, there are many classes with the same names in Java3D. That's just annoying. I can't remove Java3D from my class path because some other projects need it. How can I tell NetBeans: "For this project, please don't suggest me classes of package X"?

Use the library manager to, uh, manage your libraries! You don't have to, nor should you, have the same classpath for all your java applications on your machine. The "correct" way to use libraries in netbeans is by adding them to the project's libraries under project proerties -> libraries, either from the library manager (preferable if you are going to use the library several times across different projects) or by simply adding the jars or class directories to the project libraries, or you can even specify other netbeans projects as libraries there. That way, only the libraries you really want to use in your project will be scanned for possible classes, which will also give a huge memory/performance advantage over having each and any library in every project's search path.

Thanks, I was just to lazy to search: the Java3D was in my libext directory…

(imho) it's not a good practice to put stuff in your extlib directory as it might give you a lot of trouble when you are using different versions of some library in different projects.

Except when you install Java3D it is "kind" enough to dump the jars there.  :expressionless: