cleaned code, moved a lot of functionality to Controller. Added DataMap
to be used with JSP in the future