Refactor code to use interfaces (For category essentially)

Bug fix: [no]
Feature addition: [no]
Backwards compatibility break: [no]
Unit test passes: [yes|no]
Specs passes: [yes|no]
Replaced unit test classes removed: [yes|no]
Behat scenario passes: [yes|no]
Checkstyle issues: [yes|no]*
ChangeLog updated: [yes|no]