@@ -0,0 +1,984 @@
+package de.stevenschwenke.java.writingawesomejavacodeworkshop;%0A%0Aimport org.junit.Test;%0A%0A/**%0A * This class contains things to know about %7B@link String%7D.%0A *%0A * Extracted from Bernd M%C3%BCllers talk, see%0A * http://www.jug-ostfalen.de/article/2016/02/04/string-folien.html%0A */%0Apublic class ThingsToKnowAboutStrings %7B%0A%0A    @Test%0A    public void stringBufferAndStringBuilder() %7B%0A        // Know the difference between%0A%0A        String sbuffer = new StringBuffer(%22a%22).append(%22b%22).append(%22c%22).toString();%0A        // and%0A        String sbuilder = new StringBuilder(%22a%22).append(%22b%22).append(%22c%22).toString();%0A        // ?%0A%0A        // Note the warning at StringBuffer and StringBuilder? That's because %22+%22 is optimized in%0A        // today's JDKs and its performance is as well as those two.%0A        // HOWEVER: Don't use %22+%22 in for-loops because the compiler optimization doesn't work there.%0A    %7D%0A%0A    // There are many more things to know about Strings, but that is not the focus of this workshop.%0A%7D%0A

Add ThingsToKnowAboutStrings