add .java files

codes created before