Quick question:
While debugging Java code, Strings show up only till a certain length, after which Eclipse shows "..."
Is there any way to inspect the entire string? (This eases the pain of adding logging statements for debugging everywhere)
Quick question:
While debugging Java code, Strings show up only till a certain length, after which Eclipse shows "..."
Is there any way to inspect the entire string? (This eases the pain of adding logging statements for debugging everywhere)
In the Variables view you can right click on Details pane and select "Max Length..." popup menu. The same length applies to expression inspector popup and few other places.
If you have a really long string, I use a different strategy: dump it to a file. I have a snippet of code I use in the Display view, which is evaluated to dump the data to a file. I use Commons IO, but you can do it with JDK only methods.
org.apache.commons.io.FileUtils.writeStringToFile(new java.io.File("<filename>"), <expression to evaluate>);
Naturally, you will need the Commons IO JAR in your classpath for that to work. If you don't, resort to JDK work.