toString() Generator plugin for Eclipse

While working in my latest project, I came across a situation where I needed a toString method for my TO (Transfer Object) classes. Instead of using reflection, I simply downloaded Eclipse Plugin for toString generation. Restart the Eclipse and it is ready to be used. For any class that require a toString(), switch to Package Explorer, and right click on the class name. Select 'Generate toString' from the context menu, select the fields, and the method is there in the class!

I had this plugin for quite some time, and had actually forgotton that its not the part of Eclipse. So, in my current project, when I failed to see 'toString generator', I realized it a plugin :)

Besides toString, if you like to see equals() and hashCode() methods as well, use Commonclipse plugin.

Comments

Popular posts from this blog

Installing Bugzilla on Windows

Online Hindi Radio Stations

Copy/Paste the block of text in vi/vim