Added license headers to Java code.