axis-java-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Aleksander Slominski <as...@cs.indiana.edu>
Subject Re: [Axis2] SOAPMessage
Date Wed, 03 Aug 2005 02:31:07 GMT
Eran Chinthaka wrote:

> Current source, we have only the SOAPEnvelope that contains the soap 
> message. But IMO, I think its better to have SOAPMessage as well to 
> contain XML Declaration, Encoding, etc.,
>
> So that when sending a message transport will get the output from 
> SOAPMessage.serialize, not SOAPEnvelope.serialize.
>
>  
>
> Here are the evaluations of other alternations to solve the above problem.
>
>  
>
> 1. put those stuff in message context.
>
> Serializing code is in the envelope and it doesn't have access to the 
> message context. If someone needs to serialize he must be able to do 
> it without having a message context.
>
> 2. Put this information in OMOutputImpl. This is not practical as we 
> create a new OMOutputImpl whenever we want to serialize. So I don't 
> think it's a good idea to have state within the OMOutputImpl.
>
>  
>
> So what do you all think about this suggestion. This may involve some 
> changes to the code.
>
why not to follow XML model and in particular XML infoset? SOAP envelope 
is EII so it can have DII as parent and DII contains all this stuff 
including declaration, encoding etc - see: 
http://www.w3.org/TR/xml-infoset/#infoitem.element
"(...)* [parent]* The document or element information item which 
contains this information item in its [children] property."

it looks to me like a clean and elegant solution to the problem ...

alek

-- 
The best way to predict the future is to invent it - Alan Kay


Mime
View raw message