Modify interfaces and refactor classes