separated java code into a small project