public RingBuffer append(final char c) {
        int off = offset + length;
        off = off % buffer.length;
        buffer[off] = c;

        if (length == buffer.length) {
            offset++;
            offset = offset % buffer.length;
        } else {
            length++;
        }

        return this;
    }
Create a buffer with a specified initial size.

@param initialSize The initial size of the buffer.
stroom-util/src/test/java/stroom/util/xml/RingBuffer.java