HTML in Swing applications? Yes, you have read it right. Swing doesn’t provide components to embed HTML and I have seen lot of people asking how can we add html content in Swing applications. Your concerns have been addressed by the latest release of JavaFX which is JavaFX 2.0. You might wonder what this JavaFX …
Java
Using JsonSlurper Groovy API from Java to parse JSON
We have seen here on how to parse JSON in Java using Gson and here on how to parse JSON in Groovy. I also touched upon in brief about Groovy here. The beauty of these JVM languages is that one can invoke these APIs from Java, the only requirement is that you need to have …
Visualizing Memory Usage with VisualVM
This article is based on The Well-Grounded Java Developer, to be published Summer-2011. It is being reproduced here by permission from Manning Publications. Manning publishes MEAP (Manning Early Access Program) eBooks and pBooks. MEAPs are sold exclusively through Manning.com. All pBook purchases include free PDF, mobi and epub. When mobile formats become available all customers …
HashCode and equals methods
HashTable, HashMap and HashSet are the Collection classes in java.util package that make use of hashing algorithm to store objects. In all these Collection classes except HashSet, objects are stored as key-value pairs. For the storage and the retrieval of any user-defined objects it is a good practice to override the following methods which is …

