<html xmlns:v=3D"urn:schemas-microsoft-com:vml" xmlns:o=3D"urn:schemas-micro=
soft-com:office:office" xmlns:w=3D"urn:schemas-microsoft-com:office:word" xm=
lns:st1=3D"urn:schemas-microsoft-com:office:smarttags" xmlns=3D"http://www.w=
3.org/TR/REC-html40">
<head>
<meta http-equiv=3DContent-Type content=3D"text/html; charset=3Dus-ascii">
<meta name=3DGenerator content=3D"Microsoft Word 11 (filtered medium)">
<!--[if !mso]>
<style>
v\:* {behavior:url(#default#VML);}
o\:* {behavior:url(#default#VML);}
w\:* {behavior:url(#default#VML);}
.shape {behavior:url(#default#VML);}
</style>
<![endif]--><o:SmartTagType
namespaceuri=3D"urn:schemas-microsoft-com:office:smarttags" name=3D"PersonN=
ame"/>
<!--[if !mso]>
<style>
st1\:*{behavior:url(#default#ieooui) }
</style>
<![endif]-->
<style>
<!--
/* Font Definitions */
@font-face
        {font-family:Tahoma;
        panose-1:2 11 6 4 3 5 4 4 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0in;
        margin-bottom:.0001pt;
        font-size:12.0pt;
        font-family:"Times New Roman";
        color:black;}
h1
        {margin-top:12.0pt;
        margin-right:0in;
        margin-bottom:3.0pt;
        margin-left:0in;
        page-break-after:avoid;
        font-size:16.0pt;
        font-family:Arial;
        color:black;
        font-weight:bold;}
h2
        {margin-top:12.0pt;
        margin-right:0in;
        margin-bottom:3.0pt;
        margin-left:0in;
        page-break-after:avoid;
        font-size:14.0pt;
        font-family:Arial;
        color:black;
        font-weight:bold;
        font-style:italic;}
h3
        {margin-top:12.0pt;
        margin-right:0in;
        margin-bottom:3.0pt;
        margin-left:0in;
        page-break-after:avoid;
        font-size:13.0pt;
        font-family:Arial;
        color:black;
        font-weight:bold;}
p.MsoCaption, li.MsoCaption, div.MsoCaption
        {margin:0in;
        margin-bottom:.0001pt;
        font-size:10.0pt;
        font-family:"Times New Roman";
        color:black;
        font-weight:bold;}
p.MsoTitle, li.MsoTitle, div.MsoTitle
        {margin-top:12.0pt;
        margin-right:0in;
        margin-bottom:3.0pt;
        margin-left:0in;
        text-align:center;
        font-size:16.0pt;
        font-family:Arial;
        color:black;
        font-weight:bold;}
p.MsoBodyText, li.MsoBodyText, div.MsoBodyText
        {margin-top:0in;
        margin-right:0in;
        margin-bottom:6.0pt;
        margin-left:0in;
        text-indent:.5in;
        font-size:12.0pt;
        font-family:"Times New Roman";
        color:black;}
p.MsoSubtitle, li.MsoSubtitle, div.MsoSubtitle
        {margin-top:0in;
        margin-right:0in;
        margin-bottom:3.0pt;
        margin-left:0in;
        text-align:center;
        font-size:12.0pt;
        font-family:Arial;
        color:black;}
a:link, span.MsoHyperlink
        {color:blue;
        text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
        {color:purple;
        text-decoration:underline;}
p
        {mso-margin-top-alt:auto;
        margin-right:0in;
        mso-margin-bottom-alt:auto;
        margin-left:0in;
        font-size:12.0pt;
        font-family:"Times New Roman";
        color:black;}
pre
        {margin:0in;
        margin-bottom:.0001pt;
        font-size:10.0pt;
        font-family:"Courier New";
        color:black;}
p.code, li.code, div.code
        {margin:0in;
        margin-bottom:.0001pt;
        background:#F3F3F3;
        font-size:9.0pt;
        font-family:"Courier New";
        color:black;}
span.EmailStyle24
        {mso-style-type:personal;
        font-family:Arial;
        color:windowtext;}
span.EmailStyle25
        {mso-style-type:personal;
        font-family:Arial;
        color:navy;}
span.EmailStyle26
        {mso-style-type:personal-reply;
        font-family:Arial;
        color:navy;}
@page Section1
        {size:8.5in 11.0in;
        margin:1.0in 1.25in 1.0in 1.25in;}
div.Section1
        {page:Section1;}
-->
</style>
<!--[if gte mso 9]><xml>
<o:shapedefaults v:ext=3D"edit" spidmax=3D"1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext=3D"edit">
<o:idmap v:ext=3D"edit" data=3D"1" />
</o:shapelayout></xml><![endif]-->
</head>
<body bgcolor=3Dwhite lang=3DEN-US link=3Dblue vlink=3Dpurple>
<div class=3DSection1>
<p class=3DMsoNormal><font size=3D2 color=3Dnavy face=3DArial><span style=3D=
'font-size:
10.0pt;font-family:Arial;color:navy'>Can you please give me example of using
matches operator for startswith?<o:p></o:p></span></font></p>
<p class=3DMsoNormal><font size=3D2 color=3Dnavy face=3DArial><span style=3D=
'font-size:
10.0pt;font-family:Arial;color:navy'><o:p> </o:p></span></font></p>
<p class=3DMsoNormal><font size=3D2 color=3Dnavy face=3DArial><span style=3D=
'font-size:
10.0pt;font-family:Arial;color:navy'><o:p> </o:p></span></font></p>
<p class=3DMsoNormal><font size=3D2 color=3Dnavy face=3DArial><span style=3D=
'font-size:
10.0pt;font-family:Arial;color:navy'>Thanks,<o:p></o:p></span></font></p>
<p class=3DMsoNormal><font size=3D2 color=3Dnavy face=3DArial><span style=3D=
'font-size:
10.0pt;font-family:Arial;color:navy'>Ashwini<o:p></o:p></span></font></p>
<p class=3DMsoNormal><font size=3D2 color=3Dnavy face=3DArial><span style=3D=
'font-size:
10.0pt;font-family:Arial;color:navy'><o:p> </o:p></span></font></p>
<div>
<div class=3DMsoNormal align=3Dcenter style=3D'text-align:center'><font size=
=3D3
color=3Dblack face=3D"Times New Roman"><span style=3D'font-size:12.0pt;color=
:windowtext'>
<hr size=3D2 width=3D"100%" align=3Dcenter tabindex=3D-1>
</span></font></div>
<p class=3DMsoNormal><b><font size=3D2 color=3Dblack face=3DTahoma><span
style=3D'font-size:10.0pt;font-family:Tahoma;color:windowtext;font-weight:bo=
ld'>From:</span></font></b><font
size=3D2 color=3Dblack face=3DTahoma><span style=3D'font-size:10.0pt;font-fa=
mily:Tahoma;
color:windowtext'> rules-users-bounces@lists.jboss.org
[mailto:rules-users-bounces@lists.jboss.org] <b><span style=3D'font-weight:b=
old'>On
Behalf Of </span></b>Hehl, Thomas<br>
<b><span style=3D'font-weight:bold'>Sent:</span></b> Monday, July 09, 2007 5=
:31
PM<br>
<b><span style=3D'font-weight:bold'>To:</span></b> 'Rules Users List'<br>
<b><span style=3D'font-weight:bold'>Subject:</span></b> RE: [rules-users] ma=
tches
operator</span></font><font color=3Dblack><span style=3D'color:windowtext'><=
o:p></o:p></span></font></p>
</div>
<p class=3DMsoNormal><font size=3D3 color=3Dblack face=3D"Times New Roman"><=
span
style=3D'font-size:12.0pt'><o:p> </o:p></span></font></p>
<p class=3DMsoNormal><font size=3D2 color=3Dnavy face=3DArial><span style=3D=
'font-size:
10.0pt;font-family:Arial;color:navy'>Also, Java is far stricter on syntax fo=
r
regular expressions than anything else I've seen. You can't just test your
stuff at a unix prompt or using grep to see if it works. That's just the fir=
st
step. I generally use the vi find command.<o:p></o:p></span></font></p>
<p class=3DMsoNormal><font size=3D2 color=3Dnavy face=3DArial><span style=3D=
'font-size:
10.0pt;font-family:Arial;color:navy'><o:p> </o:p></span></font></p>
<div>
<div class=3DMsoNormal align=3Dcenter style=3D'text-align:center'><font size=
=3D3
color=3Dblack face=3D"Times New Roman"><span style=3D'font-size:12.0pt;color=
:windowtext'>
<hr size=3D2 width=3D"100%" align=3Dcenter tabindex=3D-1>
</span></font></div>
<p class=3DMsoNormal><b><font size=3D2 color=3Dblack face=3DTahoma><span
style=3D'font-size:10.0pt;font-family:Tahoma;color:windowtext;font-weight:bo=
ld'>From:</span></font></b><font
size=3D2 color=3Dblack face=3DTahoma><span style=3D'font-size:10.0pt;font-fa=
mily:Tahoma;
color:windowtext'> rules-users-bounces@lists.jboss.org
[mailto:rules-users-bounces@lists.jboss.org] <b><span style=3D'font-weight:b=
old'>On
Behalf Of </span></b>Mark Proctor<br>
<b><span style=3D'font-weight:bold'>Sent:</span></b> Monday, July 09, 2007 7=
:16
AM<br>
<b><span style=3D'font-weight:bold'>To:</span></b> <st1:PersonName w:st=3D"o=
n">Rules
Users List</st1:PersonName><br>
<b><span style=3D'font-weight:bold'>Subject:</span></b> Re: [rules-users] ma=
tches
operator</span></font><font color=3Dblack><span style=3D'color:windowtext'><=
o:p></o:p></span></font></p>
</div>
<p class=3DMsoNormal><font size=3D3 color=3Dblack face=3D"Times New Roman"><=
span
style=3D'font-size:12.0pt'><o:p> </o:p></span></font></p>
<p class=3DMsoNormal><font size=3D3 color=3Dblack face=3D"Times New Roman"><=
span
style=3D'font-size:12.0pt'>Read up on regular expression, what you just wrot=
e
there is not valid.<br>
<br>
Mark<br>
Ashwini Joshi wrote: <o:p></o:p></span></font></p>
<p class=3DMsoNormal><font size=3D2 color=3Dblack face=3DArial><span style=
=3D'font-size:
10.0pt;font-family:Arial'>Hi,<u1:p></u1:p></span></font><o:p></o:p></p>
<p class=3DMsoNormal><font size=3D2 color=3Dblack face=3DArial><span style=
=3D'font-size:
10.0pt;font-family:Arial'><u1:p> </u1:p></span></font><o:p></o:p></p>
<p class=3DMsoNormal><font size=3D2 color=3Dblack face=3DArial><span style=
=3D'font-size:
10.0pt;font-family:Arial'><u1:p> </u1:p></span></font><o:p></o:p></p>
<p class=3DMsoNormal><font size=3D2 color=3Dblack face=3DArial><span style=
=3D'font-size:
10.0pt;font-family:Arial'>Has anyone used the "matches" operator?=
<u1:p></u1:p></span></font><o:p></o:p></p>
<p class=3DMsoNormal><font size=3D2 color=3Dblack face=3DArial><span style=
=3D'font-size:
10.0pt;font-family:Arial'>In our application we need to support startWith,
endsWith operators for string variable. I am thinking of using matches
operator. But the 'matches' operator is not working. I am trying the followi=
ng
code<u1:p></u1:p></span></font><o:p></o:p></p>
<p class=3DMsoNormal><font size=3D2 color=3Dblack face=3DArial><span style=
=3D'font-size:
10.0pt;font-family:Arial'><u1:p> </u1:p></span></font><o:p></o:p></p>
<p class=3DMsoNormal><b><font size=3D2 color=3D"#960000" face=3D"Courier New=
"><span
style=3D'font-size:10.0pt;font-family:"Courier New";color:#960000;font-weigh=
t:
bold'>rule</span></font></b><font size=3D2 face=3D"Courier New"><span
style=3D'font-size:10.0pt;font-family:"Courier New"'> </span></font><font si=
ze=3D2
color=3Dgreen face=3D"Courier New"><span style=3D'font-size:10.0pt;font-fami=
ly:"Courier New";
color:green'>"Hello World"</span></font><o:p></o:p></p>
<u1:p></u1:p>
<p class=3DMsoNormal><font size=3D2 color=3Dblack face=3D"Courier New"><span
style=3D'font-size:10.0pt;font-family:"Courier New"'>  =
;
</span></font><b><font size=3D2 color=3D"#960000" face=3D"Courier New"><span
style=3D'font-size:10.0pt;font-family:"Courier New";color:#960000;font-weigh=
t:
bold'>when</span></font></b><o:p></o:p></p>
<u1:p></u1:p>
<p class=3DMsoNormal><font size=3D2 color=3Dblack face=3D"Courier New"><span
style=3D'font-size:10.0pt;font-family:"Courier New"'>  =
;
m : Message(message matches </span></font><font size=3D2 color=3Dgreen
face=3D"Courier New"><span style=3D'font-size:10.0pt;font-family:"Courier Ne=
w";
color:green'>"Hello*"</span></font><font size=3D2 face=3D"Courier=
New"><span
style=3D'font-size:10.0pt;font-family:"Courier New"'>)</span></font><o:p></o=
:p></p>
<u1:p></u1:p>
<p class=3DMsoNormal><font size=3D2 color=3Dblack face=3D"Courier New"><span
style=3D'font-size:10.0pt;font-family:"Courier New"'>  =
;
</span></font><b><font size=3D2 color=3D"#960000" face=3D"Courier New"><span
style=3D'font-size:10.0pt;font-family:"Courier New";color:#960000;font-weigh=
t:
bold'>then</span></font></b><o:p></o:p></p>
<u1:p></u1:p>
<p class=3DMsoNormal><font size=3D2 color=3Dblack face=3D"Courier New"><span
style=3D'font-size:10.0pt;font-family:"Courier New"'>  =
;
System.out.println( </span></font><font size=3D2 color=3Dgreen face=3D"Couri=
er New"><span
style=3D'font-size:10.0pt;font-family:"Courier New";color:green'>"Hello
World"</span></font><font size=3D2 face=3D"Courier New"><span
style=3D'font-size:10.0pt;font-family:"Courier New"'>); </span></font><o:p><=
/o:p></p>
<u1:p></u1:p>
<p class=3DMsoNormal><b><font size=3D2 color=3D"#960000" face=3D"Courier New=
"><span
style=3D'font-size:10.0pt;font-family:"Courier New";color:#960000;font-weigh=
t:
bold'>end</span></font></b><o:p></o:p></p>
<u1:p></u1:p>
<p class=3DMsoNormal><font size=3D2 color=3Dblack face=3DArial><span style=
=3D'font-size:
10.0pt;font-family:Arial'><u1:p> </u1:p></span></font><o:p></o:p></p>
<p class=3DMsoNormal><font size=3D2 color=3Dblack face=3DArial><span style=
=3D'font-size:
10.0pt;font-family:Arial'><u1:p> </u1:p></span></font><o:p></o:p></p>
<p class=3DMsoNormal><font size=3D2 color=3Dblack face=3DArial><span style=
=3D'font-size:
10.0pt;font-family:Arial'><u1:p> </u1:p></span></font><o:p></o:p></p>
<p class=3DMsoNormal><font size=3D2 color=3Dblack face=3DArial><span style=
=3D'font-size:
10.0pt;font-family:Arial'>And the value set in the message is "Hello Wo=
rld".
But it is not going into the then clause.<u1:p></u1:p></span></font><o:p></o=
:p></p>
<p class=3DMsoNormal><font size=3D2 color=3Dblack face=3DArial><span style=
=3D'font-size:
10.0pt;font-family:Arial'><u1:p> </u1:p></span></font><o:p></o:p></p>
<p class=3DMsoNormal><font size=3D2 color=3Dblack face=3DArial><span style=
=3D'font-size:
10.0pt;font-family:Arial'>If anyone has already used matches operator I woul=
d
like to know how we can use it for startswith, endsWith. How do we specify t=
he
regular expression? Can we use "*"<u1:p></u1:p></span></font><o:p>=
</o:p></p>
<p class=3DMsoNormal><font size=3D2 color=3Dblack face=3DArial><span style=
=3D'font-size:
10.0pt;font-family:Arial'><u1:p> </u1:p></span></font><o:p></o:p></p>
<p class=3DMsoNormal><font size=3D2 color=3Dblack face=3DArial><span style=
=3D'font-size:
10.0pt;font-family:Arial'><u1:p> </u1:p></span></font><o:p></o:p></p>
<p class=3DMsoNormal><font size=3D2 color=3Dblack face=3DArial><span style=
=3D'font-size:
10.0pt;font-family:Arial'>Thanks,<u1:p></u1:p></span></font><o:p></o:p></p>
<p class=3DMsoNormal><font size=3D2 color=3Dblack face=3DArial><span style=
=3D'font-size:
10.0pt;font-family:Arial'>Ashwini<u1:p></u1:p></span></font><o:p></o:p></p>
<p><font size=3D3 color=3Dblack face=3D"Times New Roman"><span style=3D'font=
-size:12.0pt'>DISCLAIMER
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D This e-mail may contain privileged and confid=
ential information
which is the property of Persistent Systems Pvt. Ltd. It is intended only fo=
r
the use of the individual or entity to which it is addressed. If you are not
the intended recipient, you are not authorized to read, retain, copy, print,
distribute or use this message. If you have received this communication in
error, please notify the sender and delete all copies of this message.
Persistent Systems Pvt. Ltd. does not accept any liability for virus infecte=
d
mails.<o:p></o:p></span></font></p>
<pre wrap=3D""><font size=3D2 color=3Dblack face=3D"Courier New"><span
style=3D'font-size:10.0pt'><o:p> </o:p></span></font></pre><pre
style=3D'text-align:center'><font size=3D2 color=3Dblack face=3D"Courier New=
"><span
style=3D'font-size:10.0pt'><o:p> </o:p></span></font></pre><pre
style=3D'text-align:center'><font size=3D2 color=3Dblack face=3D"Courier New=
"><span
style=3D'font-size:10.0pt'><o:p> </o:p></span></font></pre><pre
style=3D'text-align:center'><font size=3D2 color=3Dblack face=3D"Courier New=
"><span
style=3D'font-size:10.0pt'>
<hr size=3D4 width=3D"90%" align=3Dcenter>
</span></font></pre><pre style=3D'text-align:center'><font size=3D2 color=3D=
black
face=3D"Courier New"><span style=3D'font-size:10.0pt'><o:p> </o:p></spa=
n></font></pre><pre
style=3D'text-align:center'><font size=3D2 color=3Dblack face=3D"Courier New=
"><span
style=3D'font-size:10.0pt'><o:p> </o:p></span></font></pre><pre><font
size=3D2 color=3Dblack face=3D"Courier New"><span style=3D'font-size:10.0pt'=
><o:p> </o:p></span></font></pre><pre><font
size=3D2 color=3Dblack face=3D"Courier New"><span style=3D'font-size:10.0pt'=
>_______________________________________________<o:p></o:p></span></font></p=
re><pre><font
size=3D2 color=3Dblack face=3D"Courier New"><span style=3D'font-size:10.0pt'=
>rules-users mailing list<o:p></o:p></span></font></pre><pre><font
size=3D2 color=3Dblack face=3D"Courier New"><span style=3D'font-size:10.0pt'=
><a
href=3D"mailto:rules-users@lists.jboss.org">rules-users@lists.jboss.org</a><=
o:p></o:p></span></font></pre><pre><font
size=3D2 color=3Dblack face=3D"Courier New"><span style=3D'font-size:10.0pt'=
><a
href=3D"https://lists.jboss.org/mailman/listinfo/rules-users">https://lists.=
jboss.org/mailman/listinfo/rules-users</a><o:p></o:p></span></font></pre><pr=
e><font
size=3D2 color=3Dblack face=3D"Courier New"><span style=3D'font-size:10.0pt'=
> <o:p></o:p></span></font></pre>
<p class=3DMsoNormal><font size=3D3 color=3Dblack face=3D"Times New Roman"><=
span
style=3D'font-size:12.0pt'><o:p> </o:p></span></font></p>
</div>
<p>DISCLAIMER=0A=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=0A=
This e-mail may contain privileged and confidential information which is the=
property of Persistent Systems Pvt. Ltd. It is intended only for the use of=
the individual or entity to which it is addressed. If you are not the inten=
ded recipient, you are not authorized to read, retain, copy, print, distribu=
te or use this message. If you have received this communication in error, pl=
ease notify the sender and delete all copies of this message. Persistent Sys=
tems Pvt. Ltd. does not accept any liability for virus infected mails.</p>
</body>
</html>