Refactoring, changed development target to 10.9
Moved class variables into implementation file.
Refactored into smaller methods.