Introduction of page model, moved some classes into their own files