add license to some files, edit some file to compatible with jdk1.6