Java String Tutorials: Become a Java Strings Virtuoso

Intro to Java Strings

Java String
Get Ready to Learn About Java Strings!
  1. String Memory Internals by Tomasz Murkiewicz. The main point to understand here is the distinction between String Java object and its contents - char[] under private value field. String is basically a wrapper around char[] array, encapsulating it and making it impossible to modify so the String can remain immutable. Also the String class remembers which parts of this array is actually used. This all means that you can have two different String objects (quite lightweight) pointing to the same char[].

  2. Top 10 Questions of Java Strings by Ryan Wang. A discussion of ten common questions Java developers face when working with Strings. Though this is a bit of an old post (published in 2013), we hope you'll still find some value in these lessons.