sample java  io code