Caio a tutti,

avrei bisogno del vostro aiuto. Devo parsificare un file XML usando Sax ma ho un problema di character limitation (2048) che random mi taglia delle stringhe.
Immagino che dovrei scansionare tutto in un buffer ma non sono molto pratico,mi potete aiutare?
Di seguito la class Handler che uso:
class HowToHandler extends DefaultHandler {
boolean nome = false;
boolean valore = false;
int x,y=0;
int i;
private Vector<String> fileItems = new Vector<String>();
StringBuffer buf = new StringBuffer();






public void startElement(String nsURI, String strippedName, String tagName,
Attributes attributes) throws SAXException {


if ( tagName.equalsIgnoreCase("Name") )

nome = true;


if ( tagName.equalsIgnoreCase("Val") )
valore = true;
}



public void characters(char [] ch, int start, int length) {
//buf.append(new String(ch, start, length));

if ( nome ) {



fileItems.addElement((new String(ch, start, length)));

System.out.println("Prova:" + fileItems.get(x));
x++;
nome = false;


}


else
if ( valore )
{


buf.append(new String(ch, start, length));




System.out.println("PLuto:" + fileItems.get(x));
x++;
valore = false;




}



public Vector getFileItems ()
{
return fileItems;
}