Added java_home function for setting the JAVA_HOME environment and also
updating the path.

Run `java_home 1.6` to use Java 6, or `java_home 1.7` for Java 7.

Call `java_home` without any arguments to list the installed Java
versions.
Changed name of function to not conflict with the actual tool.
Added -silent parameter to avoid screen output.
Handling optional parameter in a proper manner.