Hi all,
I am having the same problem and I am not sure if there is any way out. I
think that the SequenceInputStream does not solve the problem since it is
used to join streams while what is necessary here is I think splitting the
stream.
There is some example in the Xerces samples, but it need to do some work on
both side (sender and receiver), thus it cannot be used in general.
I guess that the only solution is either to use some protocol (e.g. MLLP)
to delimit the XML data, or to close the stream by the sender to tell to
the receiver that the data are complete.
But if anyone has some clever solution please let me know.
br,
Jakub
"Devlin, Kurt" <[EMAIL PROTECTED]> on 06/14/2002 03:51:37 PM
Please respond to [EMAIL PROTECTED]
To: "'[EMAIL PROTECTED]'" <[EMAIL PROTECTED]>
cc:
Subject: RE: Parse multiple documents from same input stream.
Have you looked at java.io.SequenceInputStream?
-----Original Message-----
From: Williams, Jamin (GXS) [mailto:[EMAIL PROTECTED]
Sent: Wednesday, June 12, 2002 9:10 AM
To: [EMAIL PROTECTED]
Subject: Parse multiple documents from same input stream.
Is it possible to have xerces parse more then one XML document from
the same input stream? I have been trying with no success.
It parses the first document but throws an exception when it
encounters the next document in the stream. I stopped the parser
after the first document was read and then tried to start again from
the same point in the input stream with another parser but the first
parser had already read beyond the end of the document in the stream
so when the second parser starts it is starting past the beginning of
the second document and throws an exception.
Is there any way to do this?
Thanks.
Jamin Williams
GPE - RMS Engineering
Phone: *280-1242 x131 or (248) 324-1242 x131
Fax: *280-1265 or (248) 324-1265
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]