| Simple, fast byte-array output stream that exposes the backing array.
java.io.ByteArrayOutputStream is nice, but to get its content you
must generate each time a new object. This doesn't happen here.
This class will automatically enlarge the backing array, doubling its
size whenever new space is needed. The
FastByteArrayOutputStream.reset() method will
mark the content as empty, but will not decrease the capacity: use
FastByteArrayOutputStream.trim() for that purpose.
author: Sebastiano Vigna |