[Mono-list] Implement StrLike in C#

Benjamin Podszun ben at galactic-tales.de
Sun Sep 28 19:21:55 EDT 2008


On Sun, 28 Sep 2008 17:11:44 -0400, "Max Metral" <max at artsalliancelabs.com>
wrote:
> Wouldn't regular expressions be a better bet?

No, not at all. Without resorting to the "Now he has two problems" quote:
His link [1] describes a scenario where someone expects user input and
wants it to behave like the default windows globs/wildcards. * means 0-N
chars, ? means 0-1 chars, iirc. The link indicates that that cannot (and
doesn't want to) educate his uses how to compose regular expressions, so
this is the easier (and therefor by definition most likely the better)
solution. If the same applies for the OP (or if he's the same, although I
doubt that) regular expressions are not a good option.

Regards,
Ben

1:
http://groups.google.com/group/microsoft.public.dotnet.languages.csharp/browse_thread/thread/32649965654df408/57ba3e39a6c2711f?lnk=st&q=#57ba3
e39a6c2711f




More information about the Mono-list mailing list