Refactored, mavenised and stuff.