Add copyright info to source files and improve Javadoc (somewhat)