Add sample java code.