0

com.ximpleware.extended.XMLBuffer.getBytes() always returns null. What is the best way to modify xml using VTD-XML Huge?

DanielBarbarian
  • 5,093
  • 12
  • 35
  • 44
Muhammed K
  • 39
  • 4
  • You should tell more about your program. Include more of the source code. – Attila Repasi Oct 26 '16 at 15:54
  • How big is your xml? VTD-XML standard edition has the XMLModifier method... you don't need to use VTD-XML extended. – vtd-xml-author Oct 26 '16 at 23:22
  • My xml is 1.6 GB and it will be bigger that that also as it is retrieved from another server. Theoretically there is no upper limit of xml size. I have to use namespace aware processing. – Muhammed K Oct 27 '16 at 06:45

1 Answers1

0

For extended vtd-xml that method is supposed to return NULL.. You can not expect it to behave the same way as in standard vtd-xml... you can get a segment of bytes using some other methods

such as writeToFileOutputStream

vtd-xml-author
  • 3,319
  • 4
  • 22
  • 30
  • Using writeToFileOutputStream impact performance and defeats the purpose of using VTD-XML. Is there any possibility to have some overloaded methods which return byte arrays in chunks? – Muhammed K Oct 27 '16 at 06:43
  • My xml is 1.6 GB and I should be able to process even bigger ones. I was evaluating VTD-XML for better execution speed + less memory usage. I am sure 1.6GB file operation will be definitely slow. – Muhammed K Oct 27 '16 at 06:47
  • I have managed it with writeToFileOutputStream and after that by processing generated xml file with SAX. – Muhammed K Nov 04 '16 at 13:14