Here is my second “Call For Help” needing help for an Eclipse Tip/Trick. Obviously, being a truly rookie with Eclipse these are basic questions now, but I’m sure they’ll be more challenging questions down the road. I guess this category could be helpful to people like myself, that are trying to get productive with Eclipse.
How can I quickly get a pre-defined code block/line/snippet into a Java class in Eclipse? With Vim I could define a “bit” of code in my .vimrc file and link it to a string. When I type the string it would get replaced with the code from my .vimrc.
So for a simple System.out.println( “” ); statement I would simply type jso+Spacebar and the “jso” would be replaced with “System.out.println( “” );”. The best part was I could control where my cursor would be and if I would be in edit mode or not.
I know this can be done easily in Eclipse. The problem is me finding out how to do it? Finding out what is already defined for me and how to write my own custom code “snippets”.
I’ll report back when I’ve “cracked the code”…… That was bad, but it got a smirk out of me. Sorry.