I am using the SAX xml parser to parse some XML data containing newlines. When using the # getValue attributes, newline data is lost. How to save newlines?
The solution was to use 
 instead of \ n


you can use this code when getting a string for parsing:
public void characters(char ch[], int start, int length) { for(int i=start; i<length; i++) if(!Character.isISOControl(ch[i])) content.append(ch[i]); }
Source: https://habr.com/ru/post/1332177/More articles:GNU Prolog - fact list search - prologHow to send a push notification to an individual user in the iPhone SDK? - objective-cAndroid: Can I cut / paste the Android SDK and use it? - androidUsing a PHP variable in a text input value = statement - variablesAndroid SAX Parsing: how to save newlines using the CDATA tag - androidTemplates or ideas for a web query builder (not for reporting)? - sqlScala - Get unique values ββfrom a swirl list - scalaAjax function call - ajaxAdditional function / method definitions increase program memory? - c ++What "& 0xFFFFFFFF" does in this HIDWORD macro - c ++All Articles