If-statement as java code conventions