Community
Participate
Working Groups
I don't know if this is 3.0 specific or not. I also suspect that it has been put in on purpose, however I find it very irritating. The basic problem is that code assist hides methods if you are unable to use them because you do not have a class imported. This is even more iritating if I want to call methodA and pass the result into methodB without an assignment, so the call to methodA occurs within the parameter list of methodB. In order to see these methods I have to import the class, which will then give me a warning stating that the import is not used. I think that while this feature may seem good on the outside it is very irritating when you find that you cannot invoke a method because of a lack of an import. In many occasions I have to create a variable of that type and them remove it just to see the method. Very irritated Alasdair
Please provide exact steps to reproduce.
I have looked further into the problems I have been experiencing, and while I thought it was because I didn't have the class imported it was in fact because I did not have the class on the classpath. The steps needed to reproduce this are given below. The example given is simple, the more common one I come across is that the method I am calling throws an exception that extends another exception that I do not have on the classpath. In my environment I have projects for relativly small units of function, with interdependencies on each other. The real problem this introduces is when a project I depend on requires another one my project does not directly rely on but my project still needs to have it on its classpath. So steps to reproduce. Create Project A Create Class A in project A Create Project B Create Class B in project B Create method getA in class B that returns A Create Project C Setup class path in C so it references B, but not A Create Class C in project C Create method C in project C Attempt to use quick assist to put in a call to getA
Code assist try to propose only correct code. If A is not inside classpath then a call to getA produce a compile error. So getA is not proposed. Work as designed. Closed.