We recently wrote about watching a directory using the new APIs introduced as part of Java 7. In this post let me throw some light on another class added to the java.nio package as part of Java 7 update- java.nio.file.Files. Another piece of information related to this is that complete java.nio.file package was added as [...]
Author Archives | Mohamed Sanaulla
Implementing WatchService API in Java 7 to monitor the directory changes
June 15, 2012
In Java 7 there were quite a lot of new things added to the File NIO package (java.nio)- there was a new java.nio.file package and java.nio.file.attribute package. Main highlights of the java.nio.file package are the following classes: Path: Its an object used to locate a file or directory in the file system. The value contained [...]
Merge Sort implementation using Fork-Join Framework in Java 7
June 13, 2012
In our previous post we went through the basics of Fork-Join Framework introduced as part of Java 7. In this post lets apply the same Fork-Join to implement Merge sort algorithm. The pseudo code for Merge sort can be found here. In summary the Merge sort algorithm: 1. Divides the array into 1 parts 2. [...]
A simple Location and Weather mashup using Gaelyk Framework
June 12, 2012
In our sample Gaelyk application here we stopped at just obtaining the location information. In this post lets update that application to fetch the Weather information as well. For the weather information we make use of the Weather Underground API which provides a lot of features like geolocation information, current weather conditions, forecast weather conditions [...]
Simple introduction to Fork-Join Framework in Java 7
June 12, 2012
Fork-Join Framework was added as part of Java 7 which makes use of the ExecutorService interface to distribute tasks to the worker threads in the thread pool. The difference in Fork-Join is that the ideal worker threads can steal queued subtasks from the other tasks and execute them. There are a few important classes you [...]
Handling/Avoiding Null’s in Java using Guava versus Scala
June 9, 2012
There was a discussion about nulls in the latest episode of JavaPosse. Having been inspired from that discussion and with an urge to check out Google Guava library, I came across a way to handle Null’s in Guava which is very similar to the way Scala handles. Lets consider the Person class which is defined [...]
java.util.Objects- A static utility for objects introduced in Java 7
June 6, 2012
A lot of you would be unaware of this new static utility for objects introduced in Java 7- its the java.util.Objects class. I came across this usage of class while I was browsing through the updated Java 8 collections API. The static utility methods added as part of java.util.Objects class allow us to perform null-safe [...]
Developing Groovy based web application and deploying to Google App Engine
June 5, 2012
We have seen how to develop a ZK based application and deploy it to OpenShift. Google has also a Paas offering called Google App Engine(GAE) which supports Java, Python and Dart applications. Gaelyk is a simple Groovy based toolkit to develop and deploy application to GAE. In this article lets build a simple Gaelyk based [...]
Using Morphia- Java library for MongoDB
June 3, 2012
In our post on developing sample Todo Application using JavaFX and MongoDB, we showed how we can use MongoDB, JavaFX to create a sample application. In that post we used the API provided by MongoDB to carry out the DB operations. In this post lets look at how we can use Morphia to carry out [...]
JavaBeat Newsletter-1: What’s new and noteworthy in the Java ecosystem?
June 2, 2012
We at JavaBeat have thought of coming up with a fortnightly post, a JavaBeat Newsletter covering the latest news in the Java ecosystem be it in the Java language, Other JVM based languages, Cloud support, Tools and other frameworks and also few noteworthy posts added on JavaBeat. Here we have the first edition of JavaBeat [...]






June 18, 2012
4 Comments