Read a log into a collection (using String.split to get lines) and use Collections (Maps) to create look ups they require. Do everything with instance variables even if it's wrong.
Anonymous
You should be using a log miner and QL. Not one would write this code unless it was 20 years ago.
Check out your Company Bowl for anonymous work chats.