Broke most code in EMTree.cpp into separate header files.