MODE-2221 Moved the SelfClosingInputStream to the common package and changed it so that it only wraps (and closes) and InputStream. Refactored the binary value classes to make sure any stream returned from a binary value is wrapped into a self closing stream.
Merge pull request #1143 from hchiorean/MODE-2221-master

MODE-2221-master Moved the SelfClosingInputStream to the common package and changed it so that it only wraps (and closes) and InputStream.