Core Runtime: Java 7 changes, formatting and minor code review

Done while trying to get my head around QI-377.