Rethink debug printouts.

Most debug printouts were previously out-commented, and to enable them
we had to de-comment the printouts, fixing any new compilation issues
that arose because of non-maintenance of out-commented code.

We now introduce a better approach. Debug printouts can be
enabled/disabled per-package, and even per-class at runtime by setting
the value of a system property to ”true” or ”false”.
IOLog now dynamically determines the class + method name of the caller.

We no longer need to supply the class name to IOLog on creation and
method name when we need to print it out. Instead we determine this
through the stack trace retrieved from Thread.getStackTrace().
This is much less error-prone than the previous "manual" approach,
although it does come with some performance penalty (I miss C's
no-overhead compile-time __FILE__, __LINE__ and __FUNCTION__ macros).
ReadableFileStream.java: Fix outdated reference to variable name.
ReadableRandomAccessSubstream.java: Prevent multiple "close()" calls.

If more than one "close()" call is issued for a
ReadableRandomAccessSubstream, we dereference the underlying
SynchronizedReadableRandomAccess more than one time, possibly removing
references that others have claimed. This misuse of "close()" must be
prevented early to avoid this situation.
SynchronizedReadableRancomAccessStream.java: Lazily close source stream.

Previously the approach to closing the source stream was that the caller
should always make sure to close all substreams that are using this
SynchronizedReadableRandomAccessStream before calling "close()", which
unconditionally closes the source stream. If the caller fails to do
that, and exception is thrown and the close does not succeed.

However, this was found to be an unpractical approach since the caller
may not always have control over which substreams are created and when,
so instead we introduce the following scheme:
- On creating of the SynchronizedReadableRandomAccessStream, a reference
  is taken.
- Each new substream takes a reference, but after all substreams are
  closed there is still a reference, i.e. the "self"-reference.
- Only when the number of references reaches 0 is the source stream
  closed. This can happen on close() or it can happen on the last
  dereferencing by a substream.

This means that close() no longer guarantees that the underlying stream
is closed... it is closed only if the last substream has released its
reference. If this has not happened at the time that "close()" is
called, then the underlying stream will be kept open until the last
substream releases its reference.
SynchronizedReadableRandomAccessStream.java: Prevent bad dereferences.

If the substream would call "removeReference(Object)" multiple times, we
cannot detect it but we can at least prevent refCount from decreasing
beyond a specified point. If the stream is open, we must at least have a
reference count of 1, and otherwise at least a reference count of 0
(a negative reference count doesn't make sense).
SynchronizedReadableRandomAccessStream.java: Add warning in finalize().

If reference count on invocation of finalize() is non-0, we emit a
warning to alert that all the substreams have not been properly closed,
i.e. we are leaking the source stream in an open state.
SynchronizedReadableRandomAccessStream.java: Add references debug code.

This code, if enabled, will keep track of every reference and save its
stack trace so that when a leak is discovered we can present the full
stack trace of every addReference(Object) call for debugging purposes.
IOUtil.java: Bugfix in readFully(ReadableRandomAccessStream, Long, int).
Add single-byte readFully method to interface Readable.