code: public char[] getCharacters() {
          if (c.length == length) {
              return c;
          }
          char[] chars = new char[length];
          System.arraycopy(c, 0, chars, 0, length);
          return chars;
      }
docs: Returns the contents of the buffer as a char[]. The returned array may
  be the internal array of the buffer, so the caller must take care when
  modifying it.
  This method allows to avoid copying if the caller knows the exact capacity
  before.
  @return