Fix using Java 8 API

Fix to issue #1