I\'ve read from the apt tool page that one can create AnnotationProcessors to generate new derived files (source files, class files, deployment descriptors, etc.). I am looking
You could have
String message = Obfuscated.decode("a string that should not be readable in class file");
which compiles normally, however after compilation you have a tool which examines the bytecode e.g. using ObjectWeb's ASM, changes the String literal so it looks like
String message = Obfuscated.decode("\u86DD\u4DBB\u5166\uC13D\u4C79\uB1CD\uC313\uAE09\u1A35\u3051\uDAF6\u463B");
To make it easer to identify strings which need to be changed, you could add a prefix to them, and you could ensure this prefix does appear after the code has been obfuscated.
String s = "Obfuscate: a string that should not be readable in class file";
// later
String message = Obfuscated.decode(s);