Brian,

actually you can have to logic in your drl file.
Just get the internal NormalizedMessage of the exchange and convert the 
content to DOM document using SourceTransformer. Then change the attribute in 
that document and put it back to the message content. That should do the 
trick.

For details have a look at the drools engine source:
http://svn.apache.org/viewvc/servicemix/components/engines/servicemix-
drools/trunk/src/main/java/org/apache/servicemix/drools/

Regards
Lars


Am Donnerstag 23 Oktober 2008 14:11:25 schrieb ObjectOrange:
> Thx Lars!
>
> So, code and load a new 'helper' class that provides a setXMLAttribute()
> method?
>
> Does using these 'helper' classes interfere with the BRMS web application
> in managing the DRL files?
>
> lhe77 wrote:
> > Brian,
> >
> > of course you can change the content of the message. Just retrieve the
> > MessageExchange's InMsg (Normalized Message) and use getContent() to get
> > the
> > content of the message.
> > Useful class here to convert the content to DOM document or String is the
> > SourceTransformer class.
> >
> > Regards
> > Lars
> >
> > Am Mittwoch 22 Oktober 2008 18:15:36 schrieb ObjectOrange:
> >> Hello,
> >>
> >> I've noticed in the examples for this component the use of XPath for
> >> condition evaluation. Is there a way to update the XML within a
> >> Normalized
> >> Message perhaps setting an XML attribute to a new value using the
> >> current code or would this be a new feature?
> >>
> >> Thx!
> >>
> >> Brian

Reply via email to