Stream Utilities for Java
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
src
.gitignore
README.md
pom.xml

README.md

Streams

Simple reusable utilities for Java IO Streams.

Problem

You have some utility that is needed for your job to be done, and is about to be used as FilterStream but the utility is "nasty" and does not provide you such classes? Or, you need the exact opposites of GZIPInputStream (that ungzips from input stream) or GZIPOutputStream (that gzips to output stream)?

No problem here.

Solution

Steps needed:

  1. Wrap your nasty class with Coder interface
  2. Optionally subclass CoderInputStream and/or CoderOutputStream
  3. Use your nasty utility as FilterStream!

Look at unit tests for an example.

Have fun,
t