camel-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Claus Ibsen (JIRA)" <j...@apache.org>
Subject [jira] Created: (CAMEL-1419) PredicateBuilder - Support type converter to coerce types into compatible types for comparisons
Date Wed, 04 Mar 2009 11:16:59 GMT
PredicateBuilder - Support type converter to coerce types into compatible types for comparisons
-----------------------------------------------------------------------------------------------

                 Key: CAMEL-1419
                 URL: https://issues.apache.org/activemq/browse/CAMEL-1419
             Project: Apache Camel
          Issue Type: Improvement
          Components: camel-core
            Reporter: Claus Ibsen


Using predicates in routes in eg choice DSL does not support type convertions so you need
to do this manual or ensure types are compatible

We could improve this by testing for true until
- try with types given
- try again by convert right to left
- try again by convert left to right

This allows you to do routing, eg route with a header value as string by you can do

{code}
choice(when("foo").isEqualTo(2))...
choice(when("foo").isGreaterThan(50))...
{code}

See nabble:
http://www.nabble.com/Re%3A-Camel-Routing-based-on-bean-return-object-td22249549.html


-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


Mime
View raw message