February 14, 2003
RE: Eclipse M5: How to make it Work
Here some tips for eric (see Eclipse m5: How to make it work)
I've been using the M3 release of this truly great Intehgrated Development Environment, or IDE, for Java development. The M3 release introduced the great feature of offering to import Java classes you have referenced in your code but not imported. Eclipse flags the line as an error (which it is, since you haven't imported the class) and then the quick-fix popup offers to import the class. This is one of the best features of Eclipse, one that makes me more productive.
Go to the error, hit ctrl+space and enter on the correct class or hit the right mousebutton and select organize imports. This is a feature of 2.0.1
With Eclipse, you can check out a module from a CVS repository, for example, and make a project out of the module. (This is what the "Welcome" screen tells you to do, in fact.) But, when Eclipse makes this project, it makes a CVS project, not a Java project, even if what you have is a set of Java code. There is no way from the user interface that can tell Eclipse that the project is also a Java project. (Ideally, this would be in the project properties dialog.) If anyone knows of any way in the interface to make this change, please let me know. I have not been able to find anything.
Afterwards changing is (too bad) the way you are describing, but why didn't you just do a check out as and then select javaproject ??
You may need to restart Eclipse to have this change take effect. Your project should now be recognized as a Java project.
Just close the project concerning, edit and reopen it, you don't have to restart eclipse for that.
Another feature in M5 that proved really annoying is the toolbar icon that enables the mode to show the source of the selected item only. For some reason this was on. (I cannot say for certain if this came turned on out of the box.
I think this thing was high on the list for former visual age users. (I know a couple of people who really love this feature). I just want a big screen with everything in it btw ;)
Love eclipse btw :)
Posted by mvdb at February 14, 2003 06:21 PM
Two quick notes:
1. I don't think you get the problem I was describing. The ctrl+space could not find the class, because my project was not a Java project. Once I added the Java "nature", ctrl+space found the class name just fine. I love this feature.
2. Perforce projects, as far as I am aware, have not had the ability to "check out as" to convert to different project types.
Have fun,
-Eric
Hmm.. Was not aware that you are using perforce.. CVS has a checkout as and you can select any form of project. But indeed, it is a bit strange setup,it's even tedious to remove a nature (that eg you added by accident..)
I'm having a similar issue with opening a project from CVS, and I can't seem to get it....I checked out the directory from CVS that contains the top-level directory of all my sources, and it seems to show up fine in the Java Perspective, but when i go to the Java Hierarchy, the project isn't in the Project window! Argh! Kinda pulling my hair out here. The only other clue i have is that when i open up a source file and i try to go to the Object Hierarchy, it says the resource is not on the build path of a Java project. What is that about?
-Chris
Ok, I found a solution: when you mke the project from CVS, make sure you pick 'Import Project As..' and select a Java project. The 'default' project doesn't allow you to set up classpaths, etc.
-Chris