Java

Java

Java is an object-oriented programming language that is intended to be runnable from many different operating systems without recompiling.

XML and Java

Converting Java content into AJAX (Javascript and XML)

If you have a program in Java or know how to program in Java and would like to convert your code to be used on websites as AJAX (Javascript and XML), Google Web Toolkit can help do it for you instead of doing so by hand.

Google Web Toolkit

The Web Toolkit offers alot of tools for creating webcontent from your Java apps and is perfect for me since I dont have any experience with Javascript or XML. If you know how to program in Java, make sure to check it out.

Create a Java class that is only comparable to itself

In Java 5 and above, how to create a Java class that is only comparable to itself? The answer is to extend Comparable<TheClass>. This works even if TheClass uses generics.

public class SelfComparableOnly<T> implements Comparable<SelfComparableOnly<T>> {    ...    public int compareTo(SelfComparableOnly<T> o) {	// Compare itself to o    }    ...}

Removing old Java versions

Java is notorious for installing updates (current version as of this writing is version 6, Update 23) but not removing the old versions.

Finding a system with multiple Java versions (e.g. Java 6 Update 10, Java 6 Update 17, and Java 6 Update 20 all on the system’s Add/Remove Programs) is fairly common.

Java until recently did not provide for proper “upgrading” of old versions or cleanup of them. Fortunately Java 6 Update 23 does do this properly.

To remove older versions:

http://www.java.com/en/download/faq/remove_olderversions.xml
http://www.java.com/en/download/help/uninstall_java.xml

It is, unfortunately, fairly primitive— simply to to Add/Remove Programs or Programs and Features and remove them one at a time by uninstalling them.

Java Server Faces

Java Server Faces (JSF) Mark Norton came across a very handy web page which documents all of the standard JSF tags and includes examples in XML and graphics. http://www.horstmann.com/corejsf/jsf-tags.html