<html><head></head><body><div style="font-family: Verdana;font-size: 12.0px;"><div>Hi, Andrzej!<br/>
<br/>
I like that you like it :) To answer your question: no, in the example I gave (<br/>
set route_ref='$(route_ref),${ref|not-contained:,:route_ref}' | '$(route_ref)' | '${ref}';<br/>
) there will be no extra comma in case of repeating names. In such a case the first alternative in the rule cannot be applied but the second one ('$(route_ref)') can and so it fires, leaving the value unchanged.<br/>
So, if you had a string "1,2" and then get again a ref=2, after applying the filter the string would still be "1,2". If after that you get a ref=3, after applying the filter you get "1,2,3". So you don't have to worry about it.<br/>
Actually, I also miss conditional statements in apply block. But for now, as long as it's not possible, this filter could be useful in some situations.<br/>
<br/>
Max
<div>
<div name="quote" style="margin:10px 5px 5px 10px; padding: 10px 0 10px 10px; border-left:2px solid #C3D9E5; word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;">
<div style="margin:0 0 10px 0;"><b>Gesendet:</b> Mittwoch, 28. Januar 2015 um 17:01 Uhr<br/>
<b>Von:</b> "Andrzej Popowski" <popej@poczta.onet.pl><br/>
<b>An:</b> mkgmap-dev@lists.mkgmap.org.uk<br/>
<b>Betreff:</b> Re: [mkgmap-dev] Patch: New filter "not-contained"</div>
<div name="quoted-content">Hi Max,<br/>
<br/>
I like your idea, but application in style doesn't look good for me.<br/>
Wouldn't your rule add a superfluous comma, if name repeats?<br/>
<br/>
What I really would like to have, are conditional statements inside<br/>
apply{} block. This could be used not only to parse name, but for<br/>
example to examine member's role in relation.<br/>
<br/>
--<br/>
Best regards,<br/>
Andrzej<br/>
_______________________________________________<br/>
mkgmap-dev mailing list<br/>
mkgmap-dev@lists.mkgmap.org.uk<br/>
<a href="http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev" target="_blank">http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev</a></div>
</div>
</div>
</div></div></body></html>