The Artima Developer Community
Sponsored Link

Java Buzz Forum
Generics, IDEA and the fun to code

0 replies on 1 page.

Welcome Guest
  Sign In

Go back to the topic listing  Back to Topic List Click to reply to this topic  Reply to this Topic Click to search messages in this forum  Search Forum Click for a threaded view of the topic  Threaded View   
Previous Topic   Next Topic
Flat View: This topic has 0 replies on 1 page
Marc Logemann

Posts: 594
Nickname: loge
Registered: Sep, 2002

Marc Logemann is founder of www.logentis.de a Java consultancy
Generics, IDEA and the fun to code Posted: Sep 26, 2004 6:22 AM
Reply to this message Reply

This post originated from an RSS feed registered with Java Buzz by Marc Logemann.
Original Post: Generics, IDEA and the fun to code
Feed Title: Marc's Java Blog
Feed URL: http://www.logemann.org/day/index_java.xml
Feed Description: Java related topics for all major areas. So you will see J2ME, J2SE and J2EE issues here.
Latest Java Buzz Posts
Latest Java Buzz Posts by Marc Logemann
Latest Posts From Marc's Java Blog

Advertisement

Finally i migrated my first customer project to Java5, but migration is the wrong word, because there is no other migration than telling IDEA to use Java5 JDK. Because i am still doing J2SE Frontend stuff, i pretty much use Collections. In this case, i have a GUI screen with many fields, buttons and stuff. The dialog is a Filter dialog to filter records based on columns of a database like the one you know from Excel. Being lazy, i decided to put the components into different Lists.

Ok, now its time to put some components in there, of course, we IDEA users are kind of shortcut freaks, sometimes i use so many shortcuts that it can hardly be called coding ;-) Here its just a trivial auto-complete function, but look at the proposed type for the addition to the List. Yikes. As expected my parametrized Type JComboBox.

Getting things out of Collections, JBuilder users most likely enter the Type and reference name manually and then call the method from the List (sorry couldnt resist). In IDEA land we just enter the method call and type "CTRL+ALT+V" and IDEA does the rest, also this time, it perfectly knows what type is in the collection.

Finally i also used the new Foreach loop, which rocks in any way.

All in all, i only touched the surface of Generics by just using the generified collection classes. IDEA does its job as advertised and overall, its not a big deal, so why write about that? Because its real fun. The combination of a cool programming technique, combined with still the best IDE on this world.

Read: Generics, IDEA and the fun to code

Topic: ClientJava.com Links(6) - Concurrent Swing, Eclipse RCP Examples, MVC Mediator Framework Previous Topic   Next Topic Topic: What's happening with Huckster?

Sponsored Links



Google
  Web Artima.com   

Copyright © 1996-2019 Artima, Inc. All Rights Reserved. - Privacy Policy - Terms of Use