First cut
reorganise the code structure
Reorganise