Paul Sandoz wrote:
> Jitendra Kotamraju wrote:
>
>> Paul Sandoz wrote:
>>
>>> Hi,
>>>
>>> The JavaDoc for Message.writeTo(XMLStreamWriter) states:
>>>
>>> /**
>>> * Writes the whole SOAP message (but not attachments)
>>> * to the given writer.
>>> *
>>> * This consumes the message.
>>> * The implementation will not write
>>> * {_at_link XMLStreamWriter#writeStartDocument()}
>>> * nor
>>> * {_at_link XMLStreamWriter#writeEndDocument()}
>>
>>
>>
>
> Given that there is a 2 to 1 implementations calling
> writestart/endDocument i propose to modify StreamMessage in accordance
> with the other 2 impls and change the javadoc.
>
I made the changes and modified the jdoc (moved the not calling
writeStart/EndDocument stuff to the writePayload method).
Paul.
> Paul.
>
>> What's the reason for this ? May be Kohsuke can explain that.
>>
>> Jitu
>>
>>> *
>>> * @throws XMLStreamException
>>> * If the {_at_link XMLStreamWriter} reports an error,
>>> * or some other errors happen during the processing.
>>> */
>>> public abstract void writeTo(XMLStreamWriter sw) throws
>>>
>>> I presume it should be the responsibility of the Codec.encode
>>> implementation to call XMLStreamWriter.writeStartDocument and
>>> XMLStreamWriter.writeEndDocument?
>>>
>>> The AbstractMessageImpl and SAAJMessageImpl classes do call the
>>> writeStart/EndDocument, but the StreamMessage does not.
>>>
>>> FI requires that a writeStart/EndDocument be called so we need to be
>>> consistent. I can change the code either way...
>>>
>>> Paul.
>>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: dev-unsubscribe_at_jax-ws.dev.java.net
>> For additional commands, e-mail: dev-help_at_jax-ws.dev.java.net
>>
>
--
| ? + ? = To question
----------------\
Paul Sandoz
x38109
+33-4-76188109