Value of enter/return
I have a Saxparser implementation in Java. I'm parsing an XML file, but I want t开发者_开发技巧o skip doing something in the characters method when the character is an enter. The problem is that I have no idea how to check if the value of the char array is enter.
public void characters(char[] ch, int start, int length) {
String elementData = new String(ch, start, length);
if (!elementData.equals(valueOfEnter)){
// Dosomething
}
}
精彩评论