utility classes for Java 7