heavy refactoring.  methods extracted, instance variables created, the works