java programm to manager diaries