Moved responsibilities from Scanner to LineHandler