private void appendUnicodeEscapedCodePoint(int codePoint, StringBuilder sb, boolean escape) {
		if (escape) {
			sb.append("\\");
		}
		appendUnicodeEscapedCodePoint(codePoint, sb);
	}
Given a random string of Java unicode chars, return a new string with
 optionally appropriate quote characters for target language and possibly
 with some escaped characters.  For example, if the incoming string has
 actual newline characters, the output of this method would convert them
 to the two char sequence \n for Java, C, C++, ...  The new string has
 double-quotes around it as well.  Example String in memory:

    a"[newlinechar]b'c[carriagereturnchar]d[tab]e\f

 would be converted to the valid Java s:

    "a\"\nb'c\rd\te\\f"

 or

    a\"\nb'c\rd\te\\f

 depending on the quoted arg.
tool/src/org/antlr/v4/codegen/Target.java