reorganise code, method to add new parser