J
Joe Smith
Hi,
I haven't been able to find a short subject describing the problem (that's
also why I can't find anything in google).
I'll explain it with an example:
String original = "Hello\tbye\n";
String replaced = method(original); // Does this method exist??
System.out.println(replaced);
And what gets printed is:
Hello\tbye\n
With the escaping sequences "reversed". This way, I can copy the printed
sequence directly into the code; this may be useful, for instance, for
inserting String constants in the code, which have been programatically
created.
Does this exist?
Thanks!
I haven't been able to find a short subject describing the problem (that's
also why I can't find anything in google).
I'll explain it with an example:
String original = "Hello\tbye\n";
String replaced = method(original); // Does this method exist??
System.out.println(replaced);
And what gets printed is:
Hello\tbye\n
With the escaping sequences "reversed". This way, I can copy the printed
sequence directly into the code; this may be useful, for instance, for
inserting String constants in the code, which have been programatically
created.
Does this exist?
Thanks!