Discard the reference to the underlying buffer during close(), and throw…

… `ClosedDatabaseException` on subsequent database access.

As discussed briefly in pull request #7, currently clients can continue to access the database even after it has been closed. This prevents that, and should also help ensure the underlying database is garbage collected.