refactor #process
refactor the #process method

This has created a whole lot of additional methods. Perhaps these should
be moved into some sort of Presenter (puke) classes.
stop passing so many parameters around

The write_out* methods all use to take multiple parameters which were
actually available without having to pass them around. Made these
parameters ivars and attr_reader'ed all of them.
don't use unneccessary meta-programming
readability in write_out methods

thanks to @locks for this one
refactor raise_errors_if_arguments_are_weird as per @rking advice
clean up redundant code
extract method on redundant code