added checkstyle, changed according to checkstyle rules