added java file.
added map method.