code: public final void append(StringBuffer value)
    {
  
      if (value == null) 
        return;
      int strlen = value.length();
  
      if (0 == strlen)
        return;
  
      int copyfrom = 0;
      char[] chunk = m_array[m_lastChunk];
      int available = m_chunkSize - m_firstFree;
  
      // Repeat while data remains to be copied
      while (strlen > 0)
      {
  
        // Copy what fits
        if (available > strlen)
          available = strlen;
  
        value.getChars(copyfrom, copyfrom + available, m_array[m_lastChunk],
                       m_firstFree);
  
        strlen -= available;
        copyfrom += available;
  
        // If there's more left, allocate another chunk and continue
        if (strlen > 0)
        {
  
          // Extend array?
          int i = m_array.length;
  
          if (m_lastChunk + 1 == i)
          {
            char[][] newarray = new char[i + 16][];
  
            System.arraycopy(m_array, 0, newarray, 0, i);
  
            m_array = newarray;
          }
  
          // Advance one chunk
          chunk = m_array[++m_lastChunk];
  
          if (chunk == null)
          {
  
            // Hierarchical encapsulation
            if (m_lastChunk == 1 << m_rebundleBits
                    && m_chunkBits < m_maxChunkBits)
            {
  
              // Should do all the work of both encapsulating
              // existing data and establishing new sizes/offsets
              m_innerFSB = new FastStringBuffer(this);
            }
  
            // Add a chunk.
            chunk = m_array[m_lastChunk] = new char[m_chunkSize];
          }
  
          available = m_chunkSize;
          m_firstFree = 0;
        }
      }
  
      // Adjust the insert point in the last chunk, when we've reached it.
      m_firstFree += available;
    }
docs: Append the contents of a StringBuffer onto the FastStringBuffer,
  growing the storage if necessary.
  <p>
  NOTE THAT after calling append(), previously obtained
  references to m_array[] may no longer be valid.
  
  @param value StringBuffer whose contents are to be appended.