Thanks for everyone's help on this. I've run into yet another problem. The
in interceptor works just fine for me, but I had problems trying to figure
out how to modify the contents of an OutputStream for the out interceptor. I
looked at your logging interceptor and found that you used a
CacheAndWriteOutputStream. I tried using this in my out interceptor. I
registered a CachedOutputStreamCallback that handles the transformation in
the onClose method. The problem I have is that when I call
message.setContent() and pass it an output stream with my modified message,
it is not used. I'm assuming that I'm using the CacheAndWriteOutputStream
incorrectly. Do you have any suggestions on how I should be transforming the
contents of the OutputStream?

Thanks,
John

-----Original Message-----
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of
Daniel Kulp
Sent: Monday, August 25, 2008 4:47 PM
To: [email protected]
Cc: John Hite
Subject: Re: Using document/literal and rpc/encoded in same web service


>From the message, you can get the Exchange and from that, you can get the 
BindingOperationInfo  (exchange.get(BindingOperationInfo.class)).   From 
that, you can query the out message and from there the parts for that 
message.   In those parts should be the qnames and schema types and such.

Dan


On Monday 25 August 2008 3:51:27 pm John Hite wrote:
> Thanks, that helps a lot. I'm now stuck with a different problem.
> RPC/Encoded style messages require the types to be specified for
parameters
> and return values. Is there some way of finding the return parameter type
> information from the Message object?
>
> Thanks,
> John
>
> -----Original Message-----
> From: [EMAIL PROTECTED]
> [mailto:[EMAIL PROTECTED] On Behalf
Of
> Ian Roberts
> Sent: Wednesday, August 20, 2008 7:08 PM
> To: [email protected]
> Subject: Re: Using document/literal and rpc/encoded in same web service
>
> John Hite wrote:
> > 2) is there some way of marking the
> > messages on the way in so I know which messages need to be translated on
> > their way out?
>
> The in and out messages share the same Exchange object, so in your "in"
> interceptor, something like:
>
> message.getExchange().put("shouldUseRpcEncoded", Boolean.TRUE);
>
> and in your "out" interceptor:
>
> if(Boolean.TRUE.equals(message.getExchange().get("shouldUseRpcEncoded")))
{
>   ...
> }
>
> Ian



-- 
Daniel Kulp
[EMAIL PROTECTED]
http://www.dankulp.com/blog


Reply via email to