Return-Path: Delivered-To: apmail-activemq-camel-user-archive@locus.apache.org Received: (qmail 8027 invoked from network); 2 Oct 2008 16:00:57 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 2 Oct 2008 16:00:57 -0000 Received: (qmail 43482 invoked by uid 500); 2 Oct 2008 16:00:56 -0000 Delivered-To: apmail-activemq-camel-user-archive@activemq.apache.org Received: (qmail 43470 invoked by uid 500); 2 Oct 2008 16:00:56 -0000 Mailing-List: contact camel-user-help@activemq.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: camel-user@activemq.apache.org Delivered-To: mailing list camel-user@activemq.apache.org Received: (qmail 43459 invoked by uid 99); 2 Oct 2008 16:00:56 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 02 Oct 2008 09:00:56 -0700 X-ASF-Spam-Status: No, hits=0.2 required=10.0 tests=SPF_PASS,WHOIS_MYPRIVREG X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: local policy) Received: from [195.69.129.178] (HELO exsmtp02.exserver.dk) (195.69.129.178) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 02 Oct 2008 15:59:49 +0000 Received: from EXVS04.exserver.dk ([10.10.10.84]) by exsmtp02.exserver.dk with Microsoft SMTPSVC(6.0.3790.1830); Thu, 2 Oct 2008 17:57:33 +0200 X-MimeOLE: Produced By Microsoft Exchange V6.5 Content-class: urn:content-classes:message MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Subject: RE: Regular Expressions Date: Thu, 2 Oct 2008 17:59:41 +0200 Message-ID: <4C1FB9C00D24A140906239533638C4D2058FB6CF@EXVS04.exserver.dk> In-Reply-To: <19779910.post@talk.nabble.com> X-MS-Has-Attach: X-MS-TNEF-Correlator: Thread-Topic: Regular Expressions Thread-Index: Ackkl10rBfysh4N7RCG24DQQG5e1xQAEB0uA From: "Claus Ibsen" To: X-OriginalArrivalTime: 02 Oct 2008 15:57:33.0857 (UTC) FILETIME=[953AD910:01C924A7] X-Virus-Checked: Checked by ClamAV on apache.org Hi But it could be a good idea with a regexp(pattern) predicate add to a = builder, so you can do it with the fluent builders? I actually thought there was one already. eg to filter all kind of test users in a route: from("activemq:orders"). filter().header("username").regexp("$.*test^").to("seda:queue:justTests")= .to("bean:processOrder"); Med venlig hilsen =20 Claus Ibsen ...................................... Silverbullet Skovsg=E5rdsv=E6nget 21 8362 H=F8rning Tlf. +45 2962 7576 Web: www.silverbullet.dk -----Original Message----- From: dkozic [mailto:drazen.kozic@asw.eu]=20 Sent: 2. oktober 2008 16:03 To: camel-user@activemq.apache.org Subject: Re: Regular Expressions Thanks James Bean language is just OK. I will create custom bean for regex pattern matching. James.Strachan wrote: >=20 > 2008/10/2 dkozic : >> >> I need to inspect value of the body or value of the header against >> regular >> expression. >> It will be good if routing could be made after regexp matching. >=20 > For now the easiest way to do this is just invoke a Java method as an > expression within the routing logic. > http://activemq.apache.org/camel/bean-language.html >=20 >> Can you tell me more about helper methods you mentioned? >=20 > They are just helper methods for creating a regex expression for use = in > the DSL >=20 >=20 >=20 > --=20 > James > ------- > http://macstrac.blogspot.com/ >=20 > Open Source Integration > http://open.iona.com >=20 >=20 --=20 View this message in context: = http://www.nabble.com/Regular-Expressions-tp19778962s22882p19779910.html Sent from the Camel - Users mailing list archive at Nabble.com.