dev@jax-ws.java.net

SourceMessage

From: Kohsuke Kawaguchi <kohsuke.kawaguchi_at_sun.com>
Date: Tue, 03 Jan 2006 18:58:04 -0800

Mostly to Vivek,

Thanks for the SourceMessage class.

I wonder if it makes more sense to actually have 3 kinds of Messages for
Source --- one for SAXSource, another for StreamSource, and the other
for DOMSource.

I think StreamSource can be turned into the current StreamMessage, and
chances are DOMMessage and SAXMessage would look very different to each
other that warrants a separate implementation.

You can then have a factory method that does ugly "instanceof" 3 times
to create the right instance.

I think it makes the code easier to follow as well as faster.

-- 
Kohsuke Kawaguchi
Sun Microsystems                   kohsuke.kawaguchi_at_sun.com