Hi

You could probably use some of the scripting language in the Spring
DSL to express the tokenizer.
http://activemq.apache.org/camel/scripting-languages.html

If they have a nice one linier tokenizer method.

But of course it should be much easier out-of-the-box in pure Spring
DSL as tokenizing the body is a very common use-case for splitting
(non XML stuff)


On Mon, Dec 29, 2008 at 10:58 AM, Claus Ibsen <claus.ib...@gmail.com> wrote:
> On Sun, Dec 28, 2008 at 9:54 PM, radisb <rad...@gmail.com> wrote:
>>
>> What is the spring XML equivalent of this java DSL snippet:
>>
>> from(A).
>> splitter(body(String.class).tokenize(delimitingString)).
>> streaming().
>> to(B)
>>
>> Especially I cant find how to represent in XML the
>> "body(String.class).tokenize(delimitingString)" part:
>> <splitter streaming="true">
>> ?????????
>> </splitter>
> Yeah the Spring DSL is sometimes a bit limited compared to the full
> power of the Java DSL.
> You hit a case where the Spring DSL comes short. You want to set the
> expression that splits the body using delimiter.
>
> In the Java DSL we have expression builders for this so the syntax can
> be nice and easy. These builders is not avail in the spring DSL, so
> it's not possible to do in pure Spring DSL.
>
> We have a ticket in JIRA to improve the spring DSL
> https://issues.apache.org/activemq/browse/CAMEL-745
>
> So I guess we need to expose the ExpressionBuilder in the Spring DSL
> so you can use these builder methods in the Spring DSL directly. Then
> you get access to all these nice methods for tokenize, regexp etc.
>
> I have created a ticket for this request
> https://issues.apache.org/activemq/browse/CAMEL-1206
>
>
>>
>> Thanks
>> --
>> View this message in context: 
>> http://www.nabble.com/Splitter-in-XML-tp21196027s22882p21196027.html
>> Sent from the Camel - Users mailing list archive at Nabble.com.
>>
>>
>
>
>
> --
>
> /Claus Ibsen
> Apache Camel Committer
> Blog: http://davsclaus.blogspot.com/
>



-- 

/Claus Ibsen
Apache Camel Committer
Blog: http://davsclaus.blogspot.com/

Reply via email to