Sanjiva, /me scratches his head and wonders How come glen understands what he says - "exactly what dims describes here" and sanjiva doesn't :)
Let me try again...The DB framework will build the java objects directly from the MIME root part (this is the first step always!) and *then* accesses the other mime parts and sticks them where it is needed (or adds a reference) on the java objects that it already created. Except that OM tree is *never* built. And on the sending side, it generates stax events directly from the the java objects into the MIME root part and adds the attachments into a bag while it is doing so...again no OM tree in the picture at all. -- dims On 3/31/06, Sanjiva Weerawarana <[EMAIL PROTECTED]> wrote: > On Fri, 2006-03-31 at 09:52 -0500, Glen Daniels wrote: > > Hi dims: > > > > > May be i am missing something...the difference in my mind is a person > > > implementing a databinding layer should be able to access the > > > attachements without having to build the om tree. straight from stax > > > to java objects with no om and use whatever they need to store the > > > attachments byte arrays or data handlers or some databinding specific > > > construct. > > What's buffered are the bytes of the MIME root part that contains the > SOAP envelope. I agree we shouldn't build the tree for that part (and > I'm pretty certain we don't) until its needed but the bytes have to be > read and buffered. Unless you guys know of some magic technology I don't > see how that can be done any other way ;-) .. a stream is ordered you > know and those bytes come after these bytes. Simple as that. > > > +1. OM was built to allow you to optimize out the > > tree-building/buffering for the normal XML case - you call > > getXMLStreamReaderWithoutCaching() and go. MTOM/attachments are sort of > > the fly in the ointment there, in that you need another layer below StAX > > in order to get at the attachments. We've got that layer now, but it's > > hidden and tightly coupled to the OM tree framework. The suggestion is > > simply to open it up so you can do exactly what dims describes here. > > Ah ok that part I agree with .. that getting to the MIME data via the > MIMEHelper is a good thing. Is that what you're looking for? > > Sanjiva. > > -- Davanum Srinivas : http://wso2.com/blogs/