introduced checkstyle and removed some warnings