doing code organization to bring hci file reading and java io stream reading together.