Added sample java application code