private String readBuffer(InputNode from) throws Exception {
  int length=text.length();
  if (length > 0) {
    String value=text.toString();
    text.setLength(0);
    return value;
  }
  return null;
}

private String readBuffer ( InputNode from ) throws Exception { int length = text . length ( ) ; if ( length > 0 ) { String value = text . toString ( ) ; text . setLength ( 0 ) ; return value ; } return null ; }
this is used to read the text between element tags . if there is any text held in the buffer then this will return that text and clear the buffer . clearing the buffer in this way means that the text can only ever be read once .
