Add exception heirarchy

Custom exception types should be used to facilitate fine-grained
exception handling.

Avoid throwing or catching Throwable: there's nothing you can do to
handle an OutOfMemoryError so don't even try to catch it.
Add logging framework

SLF4J is a powerful logging facade. Much better than logging directly to
System.out and System.err.
Add unit test for ResourceReader

Refactor ResourceReader to use standard Java conventions. Unit test will
ensure correct functionality after further refactorings.