Added javadoc and copyright comments.