Rope

This is essentially an immutable String except many operations that would be  with normal strings are instead  or 

Ropes will be slower and take more memory than small Strings but they have an asymptotic advantage when working with large documents.