Added commenting tidied up classes somewhat